aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/rtc/rtc-davinci.c
diff options
context:
space:
mode:
authorJohn Stultz <john.stultz@linaro.org>2011-02-03 15:02:07 -0500
committerJohn Stultz <john.stultz@linaro.org>2011-03-09 14:23:35 -0500
commit696160fec162601d06940862b5b3aa4460344c1b (patch)
tree63c5d1d87f140b6a989256727b62071dd19d894b /drivers/rtc/rtc-davinci.c
parent80d4bb515b78f38738f3378fd1be6039063ab040 (diff)
RTC: Cleanup rtc_class_ops->irq_set_freq()
With the generic rtc code now emulating PIE mode irqs via an hrtimer, no one calls the rtc_class_ops->irq_set_freq call. This patch removes the hook and deletes the driver functions if no one else calls them. CC: Thomas Gleixner <tglx@linutronix.de> CC: Alessandro Zummo <a.zummo@towertech.it> CC: Marcelo Roberto Jimenez <mroberto@cpti.cetuc.puc-rio.br> CC: rtc-linux@googlegroups.com Signed-off-by: John Stultz <john.stultz@linaro.org>
Diffstat (limited to 'drivers/rtc/rtc-davinci.c')
-rw-r--r--drivers/rtc/rtc-davinci.c17
1 files changed, 0 insertions, 17 deletions
diff --git a/drivers/rtc/rtc-davinci.c b/drivers/rtc/rtc-davinci.c
index 92da73d40e13..dfd98a235ad1 100644
--- a/drivers/rtc/rtc-davinci.c
+++ b/drivers/rtc/rtc-davinci.c
@@ -473,22 +473,6 @@ static int davinci_rtc_set_alarm(struct device *dev, struct rtc_wkalrm *alm)
473 return 0; 473 return 0;
474} 474}
475 475
476static int davinci_rtc_irq_set_freq(struct device *dev, int freq)
477{
478 struct davinci_rtc *davinci_rtc = dev_get_drvdata(dev);
479 unsigned long flags;
480 u16 tmr_counter = (0x8000 >> (ffs(freq) - 1));
481
482 spin_lock_irqsave(&davinci_rtc_lock, flags);
483
484 rtcss_write(davinci_rtc, tmr_counter & 0xFF, PRTCSS_RTC_TMR0);
485 rtcss_write(davinci_rtc, (tmr_counter & 0xFF00) >> 8, PRTCSS_RTC_TMR1);
486
487 spin_unlock_irqrestore(&davinci_rtc_lock, flags);
488
489 return 0;
490}
491
492static struct rtc_class_ops davinci_rtc_ops = { 476static struct rtc_class_ops davinci_rtc_ops = {
493 .ioctl = davinci_rtc_ioctl, 477 .ioctl = davinci_rtc_ioctl,
494 .read_time = davinci_rtc_read_time, 478 .read_time = davinci_rtc_read_time,
@@ -496,7 +480,6 @@ static struct rtc_class_ops davinci_rtc_ops = {
496 .alarm_irq_enable = davinci_rtc_alarm_irq_enable, 480 .alarm_irq_enable = davinci_rtc_alarm_irq_enable,
497 .read_alarm = davinci_rtc_read_alarm, 481 .read_alarm = davinci_rtc_read_alarm,
498 .set_alarm = davinci_rtc_set_alarm, 482 .set_alarm = davinci_rtc_set_alarm,
499 .irq_set_freq = davinci_rtc_irq_set_freq,
500}; 483};
501 484
502static int __init davinci_rtc_probe(struct platform_device *pdev) 485static int __init davinci_rtc_probe(struct platform_device *pdev)