• NeilBrown's avatar
    rtc: Expire alarms after the time is set. · 93b2ec01
    NeilBrown authored
    If the alarm time programming in the rtc is ever in the past, it won't fire,
    and any other alarm will be queued after it so they won't fire either.
    
    So any time that the alarm might be in the past, we need to trigger
    the irq handler to ensure the old alarm is cleared and the timer queue
    is fully in the future.
    
    This can happen:
     - when we first initialise the alarm
     - when we set the time in the rtc.
    
    so follow both of these by scheduling the timer work function.
    
    CC: stable@kernel.org
    Signed-off-by: default avatarNeilBrown <neilb@suse.de>
    [Also catch set_mmss case -jstultz]
    Signed-off-by: default avatarJohn Stultz <john.stultz@linaro.org>
    93b2ec01
interface.c 23.2 KB