aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/rtc/rtc-ds1511.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/rtc/rtc-ds1511.c')
-rw-r--r--drivers/rtc/rtc-ds1511.c17
1 files changed, 0 insertions, 17 deletions
diff --git a/drivers/rtc/rtc-ds1511.c b/drivers/rtc/rtc-ds1511.c
index 37268e97de4..3fffd708711 100644
--- a/drivers/rtc/rtc-ds1511.c
+++ b/drivers/rtc/rtc-ds1511.c
@@ -397,29 +397,12 @@ static int ds1511_rtc_alarm_irq_enable(struct device *dev, unsigned int enabled)
397 return 0; 397 return 0;
398} 398}
399 399
400static int ds1511_rtc_update_irq_enable(struct device *dev,
401 unsigned int enabled)
402{
403 struct platform_device *pdev = to_platform_device(dev);
404 struct rtc_plat_data *pdata = platform_get_drvdata(pdev);
405
406 if (pdata->irq <= 0)
407 return -EINVAL;
408 if (enabled)
409 pdata->irqen |= RTC_UF;
410 else
411 pdata->irqen &= ~RTC_UF;
412 ds1511_rtc_update_alarm(pdata);
413 return 0;
414}
415
416static const struct rtc_class_ops ds1511_rtc_ops = { 400static const struct rtc_class_ops ds1511_rtc_ops = {
417 .read_time = ds1511_rtc_read_time, 401 .read_time = ds1511_rtc_read_time,
418 .set_time = ds1511_rtc_set_time, 402 .set_time = ds1511_rtc_set_time,
419 .read_alarm = ds1511_rtc_read_alarm, 403 .read_alarm = ds1511_rtc_read_alarm,
420 .set_alarm = ds1511_rtc_set_alarm, 404 .set_alarm = ds1511_rtc_set_alarm,
421 .alarm_irq_enable = ds1511_rtc_alarm_irq_enable, 405 .alarm_irq_enable = ds1511_rtc_alarm_irq_enable,
422 .update_irq_enable = ds1511_rtc_update_irq_enable,
423}; 406};
424 407
425 static ssize_t 408 static ssize_t