Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit bd729d72 authored by John Stultz's avatar John Stultz
Browse files

rtc: Avoid setting alarm to a time in the past



In some cases at boot up, the RTC alarm may be set in the past,
but still have the enabled flag on. This was causing problems,
because we would then enqueue the alarm into the timerqueue,
but it would never fire. This would clog up the timerqueue
and keep other alarms from working.

The fix is to check the alarm against the current rtc time at
boot and avoid enqueueing the alarm if it is in the past.

Reported-by: default avatarNeilBrown <neilb@suse.de>
Tested-by: default avatarNeilBrown <neilb@suse.de>
Tested-by: default avatarSander Eikelenboom <linux@eikelenboom.it>
Signed-off-by: default avatarJohn Stultz <john.stultz@linaro.org>
parent a99cbf6b
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment