rk: alarm: disable rtc alarm irq when shutdown
author黄涛 <huangtao@rock-chips.com>
Thu, 14 Mar 2013 10:31:11 +0000 (18:31 +0800)
committer黄涛 <huangtao@rock-chips.com>
Mon, 18 Mar 2013 01:31:34 +0000 (09:31 +0800)
drivers/rtc/alarm.c

index 2c9492ad38cff94da6fd5e5608e571552b5a546f..3ad91d9e42992bcadd1953a89ab78cfe199c9eac 100644 (file)
@@ -465,14 +465,9 @@ static int alarm_resume(struct platform_device *pdev)
 
 static void alarm_shutdown(struct platform_device *pdev)
 {
-       struct rtc_wkalrm alarm;
-
        pr_alarm(FLOW, "alarm_shutdown(%p)\n", pdev);
 
-       memset(&alarm, 0, sizeof(alarm));
-       rtc_time_to_tm(0, &alarm.time);
-       alarm.enabled = 0;
-       rtc_set_alarm(alarm_rtc_dev, &alarm);
+       rtc_alarm_irq_enable(alarm_rtc_dev, false);
 }
 
 static struct rtc_task alarm_rtc_task = {