aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/rtc
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2014-10-13 18:53:10 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2014-10-13 20:18:19 -0400
commit3ff38237f183ecd8a190318e0046138b92ee5e35 (patch)
treed07c9e7c8078fb36f6c5c6e2fcc572e57ce14ee7 /drivers/rtc
parente698a51239f26c370247d759da9ea016f5841fc3 (diff)
drivers/rtc/rtc-pcf8563.c: fix pcf8563_irq() error return value
As pointed out by Sergei Shtylyov, the pcf8563_irq function contains a bug in the error handling: an interrupt handler is not supposed to return an errno value but an 'enum irqreturn'. Let's fix this by returning IRQ_NONE in case of a communication error. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Cc: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> 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>
Diffstat (limited to 'drivers/rtc')
-rw-r--r--drivers/rtc/rtc-pcf8563.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/rtc/rtc-pcf8563.c b/drivers/rtc/rtc-pcf8563.c
index 3a6f994c4da8..c2ef0a22ee94 100644
--- a/drivers/rtc/rtc-pcf8563.c
+++ b/drivers/rtc/rtc-pcf8563.c
@@ -168,7 +168,7 @@ static irqreturn_t pcf8563_irq(int irq, void *dev_id)
168 168
169 err = pcf8563_get_alarm_mode(pcf8563->client, NULL, &pending); 169 err = pcf8563_get_alarm_mode(pcf8563->client, NULL, &pending);
170 if (err) 170 if (err)
171 return err; 171 return IRQ_NONE;
172 172
173 if (pending) { 173 if (pending) {
174 rtc_update_irq(pcf8563->rtc, 1, RTC_IRQF | RTC_AF); 174 rtc_update_irq(pcf8563->rtc, 1, RTC_IRQF | RTC_AF);