aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorLars-Peter Clausen <lars@metafoo.de>2011-05-26 19:25:10 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2011-05-26 20:12:33 -0400
commit3d62b8f59bb8bd08d8e3df3ab3174aab2971d6e6 (patch)
tree05fac449e2b583a98b0ef4fcbd4176d08e2dac5a /drivers
parent0942a71e435f5198921e8f072540f208f0176542 (diff)
drivers/rtc/rtc-pcf50633.c: don't request update IRQ
Commit 51ba60c5 ("RTC: Cleanup rtc_class_ops->update_irq_enable()") removed the only user of the update IRQ, so there is no need to manage it any more. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Alessandro Zummo <a.zummo@towertech.it> Cc: Marcelo Roberto Jimenez <mroberto@cpti.cetuc.puc-rio.br> Cc: John Stultz <john.stultz@linaro.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/rtc/rtc-pcf50633.c23
1 files changed, 3 insertions, 20 deletions
diff --git a/drivers/rtc/rtc-pcf50633.c b/drivers/rtc/rtc-pcf50633.c
index f90c574f9d05..0c423892923c 100644
--- a/drivers/rtc/rtc-pcf50633.c
+++ b/drivers/rtc/rtc-pcf50633.c
@@ -58,7 +58,6 @@ struct pcf50633_time {
58 58
59struct pcf50633_rtc { 59struct pcf50633_rtc {
60 int alarm_enabled; 60 int alarm_enabled;
61 int second_enabled;
62 int alarm_pending; 61 int alarm_pending;
63 62
64 struct pcf50633 *pcf; 63 struct pcf50633 *pcf;
@@ -143,7 +142,7 @@ static int pcf50633_rtc_set_time(struct device *dev, struct rtc_time *tm)
143{ 142{
144 struct pcf50633_rtc *rtc; 143 struct pcf50633_rtc *rtc;
145 struct pcf50633_time pcf_tm; 144 struct pcf50633_time pcf_tm;
146 int second_masked, alarm_masked, ret = 0; 145 int alarm_masked, ret = 0;
147 146
148 rtc = dev_get_drvdata(dev); 147 rtc = dev_get_drvdata(dev);
149 148
@@ -162,11 +161,8 @@ static int pcf50633_rtc_set_time(struct device *dev, struct rtc_time *tm)
162 pcf_tm.time[PCF50633_TI_SEC]); 161 pcf_tm.time[PCF50633_TI_SEC]);
163 162
164 163
165 second_masked = pcf50633_irq_mask_get(rtc->pcf, PCF50633_IRQ_SECOND);
166 alarm_masked = pcf50633_irq_mask_get(rtc->pcf, PCF50633_IRQ_ALARM); 164 alarm_masked = pcf50633_irq_mask_get(rtc->pcf, PCF50633_IRQ_ALARM);
167 165
168 if (!second_masked)
169 pcf50633_irq_mask(rtc->pcf, PCF50633_IRQ_SECOND);
170 if (!alarm_masked) 166 if (!alarm_masked)
171 pcf50633_irq_mask(rtc->pcf, PCF50633_IRQ_ALARM); 167 pcf50633_irq_mask(rtc->pcf, PCF50633_IRQ_ALARM);
172 168
@@ -175,8 +171,6 @@ static int pcf50633_rtc_set_time(struct device *dev, struct rtc_time *tm)
175 PCF50633_TI_EXTENT, 171 PCF50633_TI_EXTENT,
176 &pcf_tm.time[0]); 172 &pcf_tm.time[0]);
177 173
178 if (!second_masked)
179 pcf50633_irq_unmask(rtc->pcf, PCF50633_IRQ_SECOND);
180 if (!alarm_masked) 174 if (!alarm_masked)
181 pcf50633_irq_unmask(rtc->pcf, PCF50633_IRQ_ALARM); 175 pcf50633_irq_unmask(rtc->pcf, PCF50633_IRQ_ALARM);
182 176
@@ -250,15 +244,8 @@ static void pcf50633_rtc_irq(int irq, void *data)
250{ 244{
251 struct pcf50633_rtc *rtc = data; 245 struct pcf50633_rtc *rtc = data;
252 246
253 switch (irq) { 247 rtc_update_irq(rtc->rtc_dev, 1, RTC_AF | RTC_IRQF);
254 case PCF50633_IRQ_ALARM: 248 rtc->alarm_pending = 1;
255 rtc_update_irq(rtc->rtc_dev, 1, RTC_AF | RTC_IRQF);
256 rtc->alarm_pending = 1;
257 break;
258 case PCF50633_IRQ_SECOND:
259 rtc_update_irq(rtc->rtc_dev, 1, RTC_UF | RTC_IRQF);
260 break;
261 }
262} 249}
263 250
264static int __devinit pcf50633_rtc_probe(struct platform_device *pdev) 251static int __devinit pcf50633_rtc_probe(struct platform_device *pdev)
@@ -282,9 +269,6 @@ static int __devinit pcf50633_rtc_probe(struct platform_device *pdev)
282 269
283 pcf50633_register_irq(rtc->pcf, PCF50633_IRQ_ALARM, 270 pcf50633_register_irq(rtc->pcf, PCF50633_IRQ_ALARM,
284 pcf50633_rtc_irq, rtc); 271 pcf50633_rtc_irq, rtc);
285 pcf50633_register_irq(rtc->pcf, PCF50633_IRQ_SECOND,
286 pcf50633_rtc_irq, rtc);
287
288 return 0; 272 return 0;
289} 273}
290 274
@@ -295,7 +279,6 @@ static int __devexit pcf50633_rtc_remove(struct platform_device *pdev)
295 rtc = platform_get_drvdata(pdev); 279 rtc = platform_get_drvdata(pdev);
296 280
297 pcf50633_free_irq(rtc->pcf, PCF50633_IRQ_ALARM); 281 pcf50633_free_irq(rtc->pcf, PCF50633_IRQ_ALARM);
298 pcf50633_free_irq(rtc->pcf, PCF50633_IRQ_SECOND);
299 282
300 rtc_device_unregister(rtc->rtc_dev); 283 rtc_device_unregister(rtc->rtc_dev);
301 kfree(rtc); 284 kfree(rtc);