From 3ff38237f183ecd8a190318e0046138b92ee5e35 Mon Sep 17 00:00:00 2001 From: Arnd Bergmann Date: Mon, 13 Oct 2014 15:53:10 -0700 Subject: [PATCH] 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 Cc: Sergei Shtylyov Cc: Alessandro Zummo Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/rtc/rtc-pcf8563.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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) err = pcf8563_get_alarm_mode(pcf8563->client, NULL, &pending); if (err) - return err; + return IRQ_NONE; if (pending) { rtc_update_irq(pcf8563->rtc, 1, RTC_IRQF | RTC_AF); -- 2.39.5