summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Luebbe <jlu@pengutronix.de>2013-02-04 14:28:53 -0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-02-11 08:16:48 -0800
commit76913678c4d2fe2876865b7ed944178db324db1f (patch)
treef38fc288f8019ee598b5f3674df0bd688b9d7b55
parent466affeee2693763724e1ee351788455cfd1ba41 (diff)
downloadlwn-76913678c4d2fe2876865b7ed944178db324db1f.tar.gz
lwn-76913678c4d2fe2876865b7ed944178db324db1f.zip
drivers/rtc/rtc-isl1208.c: call rtc_update_irq() from the alarm irq handler
commit 72fca4a4b32dc778b5b885c3498700e42b610d49 upstream. Previously the alarm event was not propagated into the RTC subsystem. By adding a call to rtc_update_irq, this fixes a timeout problem with the hwclock utility. Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Cc: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/rtc/rtc-isl1208.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/rtc/rtc-isl1208.c b/drivers/rtc/rtc-isl1208.c
index da8beb8cae51..627b66aa78d1 100644
--- a/drivers/rtc/rtc-isl1208.c
+++ b/drivers/rtc/rtc-isl1208.c
@@ -494,6 +494,7 @@ isl1208_rtc_interrupt(int irq, void *data)
{
unsigned long timeout = jiffies + msecs_to_jiffies(1000);
struct i2c_client *client = data;
+ struct rtc_device *rtc = i2c_get_clientdata(client);
int handled = 0, sr, err;
/*
@@ -516,6 +517,8 @@ isl1208_rtc_interrupt(int irq, void *data)
if (sr & ISL1208_REG_SR_ALM) {
dev_dbg(&client->dev, "alarm!\n");
+ rtc_update_irq(rtc, 1, RTC_IRQF | RTC_AF);
+
/* Clear the alarm */
sr &= ~ISL1208_REG_SR_ALM;
sr = i2c_smbus_write_byte_data(client, ISL1208_REG_SR, sr);