aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/rtc/interface.c5
-rw-r--r--drivers/rtc/rtc-mpc5121.c2
2 files changed, 7 insertions, 0 deletions
diff --git a/drivers/rtc/interface.c b/drivers/rtc/interface.c
index dc87eda65814..eb415bd76494 100644
--- a/drivers/rtc/interface.c
+++ b/drivers/rtc/interface.c
@@ -458,6 +458,11 @@ int rtc_update_irq_enable(struct rtc_device *rtc, unsigned int enabled)
458 if (rtc->uie_rtctimer.enabled == enabled) 458 if (rtc->uie_rtctimer.enabled == enabled)
459 goto out; 459 goto out;
460 460
461 if (rtc->uie_unsupported) {
462 err = -EINVAL;
463 goto out;
464 }
465
461 if (enabled) { 466 if (enabled) {
462 struct rtc_time tm; 467 struct rtc_time tm;
463 ktime_t now, onesec; 468 ktime_t now, onesec;
diff --git a/drivers/rtc/rtc-mpc5121.c b/drivers/rtc/rtc-mpc5121.c
index 9d3caccfc250..613447abdbe5 100644
--- a/drivers/rtc/rtc-mpc5121.c
+++ b/drivers/rtc/rtc-mpc5121.c
@@ -360,6 +360,8 @@ static int __devinit mpc5121_rtc_probe(struct platform_device *op)
360 &mpc5200_rtc_ops, THIS_MODULE); 360 &mpc5200_rtc_ops, THIS_MODULE);
361 } 361 }
362 362
363 rtc->rtc->uie_unsupported = 1;
364
363 if (IS_ERR(rtc->rtc)) { 365 if (IS_ERR(rtc->rtc)) {
364 err = PTR_ERR(rtc->rtc); 366 err = PTR_ERR(rtc->rtc);
365 goto out_free_irq; 367 goto out_free_irq;