diff options
-rw-r--r-- | kernel/time/alarmtimer.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/kernel/time/alarmtimer.c b/kernel/time/alarmtimer.c index 8a46f5d64504..c16548807f1e 100644 --- a/kernel/time/alarmtimer.c +++ b/kernel/time/alarmtimer.c | |||
@@ -46,9 +46,10 @@ static struct alarm_base { | |||
46 | static ktime_t freezer_delta; | 46 | static ktime_t freezer_delta; |
47 | static DEFINE_SPINLOCK(freezer_delta_lock); | 47 | static DEFINE_SPINLOCK(freezer_delta_lock); |
48 | 48 | ||
49 | static struct rtc_timer rtctimer; | ||
50 | |||
49 | #ifdef CONFIG_RTC_CLASS | 51 | #ifdef CONFIG_RTC_CLASS |
50 | /* rtc timer and device for setting alarm wakeups at suspend */ | 52 | /* rtc timer and device for setting alarm wakeups at suspend */ |
51 | static struct rtc_timer rtctimer; | ||
52 | static struct rtc_device *rtcdev; | 53 | static struct rtc_device *rtcdev; |
53 | static DEFINE_SPINLOCK(rtcdev_lock); | 54 | static DEFINE_SPINLOCK(rtcdev_lock); |
54 | 55 | ||
@@ -783,6 +784,8 @@ static int __init alarmtimer_init(void) | |||
783 | .nsleep = alarm_timer_nsleep, | 784 | .nsleep = alarm_timer_nsleep, |
784 | }; | 785 | }; |
785 | 786 | ||
787 | rtc_timer_init(&rtctimer, NULL, NULL); | ||
788 | |||
786 | posix_timers_register_clock(CLOCK_REALTIME_ALARM, &alarm_clock); | 789 | posix_timers_register_clock(CLOCK_REALTIME_ALARM, &alarm_clock); |
787 | posix_timers_register_clock(CLOCK_BOOTTIME_ALARM, &alarm_clock); | 790 | posix_timers_register_clock(CLOCK_BOOTTIME_ALARM, &alarm_clock); |
788 | 791 | ||