aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/rtc
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2009-11-04 11:10:51 -0500
committerSamuel Ortiz <sameo@linux.intel.com>2009-12-13 13:21:39 -0500
commit5a65edbc12b6b34ef912114f1fc8215786f85b25 (patch)
treeffe43bd1234b52ad1c3774b096a51594aabe49ad /drivers/rtc
parentb9f96b5dcb1e2a75d142e481b77805ffdc6ccea6 (diff)
mfd: Convert wm8350 IRQ handlers to irq_handler_t
This is done as simple code transformation, the semantics of the IRQ API provided by the core are are still very different to those of genirq (mainly with regard to masking). Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'drivers/rtc')
-rw-r--r--drivers/rtc/rtc-wm8350.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/drivers/rtc/rtc-wm8350.c b/drivers/rtc/rtc-wm8350.c
index c91edc572eb6..56e56e552813 100644
--- a/drivers/rtc/rtc-wm8350.c
+++ b/drivers/rtc/rtc-wm8350.c
@@ -315,9 +315,9 @@ static int wm8350_rtc_update_irq_enable(struct device *dev,
315 return 0; 315 return 0;
316} 316}
317 317
318static void wm8350_rtc_alarm_handler(struct wm8350 *wm8350, int irq, 318static irqreturn_t wm8350_rtc_alarm_handler(int irq, void *data)
319 void *data)
320{ 319{
320 struct wm8350 *wm8350 = data;
321 struct rtc_device *rtc = wm8350->rtc.rtc; 321 struct rtc_device *rtc = wm8350->rtc.rtc;
322 int ret; 322 int ret;
323 323
@@ -330,14 +330,18 @@ static void wm8350_rtc_alarm_handler(struct wm8350 *wm8350, int irq,
330 dev_err(&(wm8350->rtc.pdev->dev), 330 dev_err(&(wm8350->rtc.pdev->dev),
331 "Failed to disable alarm: %d\n", ret); 331 "Failed to disable alarm: %d\n", ret);
332 } 332 }
333
334 return IRQ_HANDLED;
333} 335}
334 336
335static void wm8350_rtc_update_handler(struct wm8350 *wm8350, int irq, 337static irqreturn_t wm8350_rtc_update_handler(int irq, void *data)
336 void *data)
337{ 338{
339 struct wm8350 *wm8350 = data;
338 struct rtc_device *rtc = wm8350->rtc.rtc; 340 struct rtc_device *rtc = wm8350->rtc.rtc;
339 341
340 rtc_update_irq(rtc, 1, RTC_IRQF | RTC_UF); 342 rtc_update_irq(rtc, 1, RTC_IRQF | RTC_UF);
343
344 return IRQ_HANDLED;
341} 345}
342 346
343static const struct rtc_class_ops wm8350_rtc_ops = { 347static const struct rtc_class_ops wm8350_rtc_ops = {
@@ -459,10 +463,12 @@ static int wm8350_rtc_probe(struct platform_device *pdev)
459 wm8350_mask_irq(wm8350, WM8350_IRQ_RTC_PER); 463 wm8350_mask_irq(wm8350, WM8350_IRQ_RTC_PER);
460 464
461 wm8350_register_irq(wm8350, WM8350_IRQ_RTC_SEC, 465 wm8350_register_irq(wm8350, WM8350_IRQ_RTC_SEC,
462 wm8350_rtc_update_handler, NULL); 466 wm8350_rtc_update_handler, 0,
467 "RTC Seconds", wm8350);
463 468
464 wm8350_register_irq(wm8350, WM8350_IRQ_RTC_ALM, 469 wm8350_register_irq(wm8350, WM8350_IRQ_RTC_ALM,
465 wm8350_rtc_alarm_handler, NULL); 470 wm8350_rtc_alarm_handler, 0,
471 "RTC Alarm", wm8350);
466 wm8350_unmask_irq(wm8350, WM8350_IRQ_RTC_ALM); 472 wm8350_unmask_irq(wm8350, WM8350_IRQ_RTC_ALM);
467 473
468 return 0; 474 return 0;