From 3726a21833c9c96255735bddb5dacc8eacbff3ef Mon Sep 17 00:00:00 2001 From: Mylène Josserand Date: Tue, 29 Mar 2016 08:56:04 +0200 Subject: rtc: m41t80: add wakealarm functionality MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit To enable the wakealarm, the device must be able to wakeup. This is done by setting the device wakeup capability to true with 'device_init_wakeup' function. Signed-off-by: Mylène Josserand Signed-off-by: Alexandre Belloni --- drivers/rtc/rtc-m41t80.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'drivers/rtc') diff --git a/drivers/rtc/rtc-m41t80.c b/drivers/rtc/rtc-m41t80.c index c72473864418..5706e99853a3 100644 --- a/drivers/rtc/rtc-m41t80.c +++ b/drivers/rtc/rtc-m41t80.c @@ -758,6 +758,8 @@ static int m41t80_probe(struct i2c_client *client, m41t80_rtc_ops.read_alarm = m41t80_read_alarm; m41t80_rtc_ops.set_alarm = m41t80_set_alarm; m41t80_rtc_ops.alarm_irq_enable = m41t80_alarm_irq_enable; + /* Enable the wakealarm */ + device_init_wakeup(&client->dev, true); } } -- cgit v1.2.3