Commit-ID: 330a1617b0a6268d427aa5922c94d082b1d3e96d Gitweb: http://git.kernel.org/tip/330a1617b0a6268d427aa5922c94d082b1d3e96d Author: John Stultz <john.stultz@xxxxxxxxxx> AuthorDate: Wed, 11 Dec 2013 19:10:36 -0800 Committer: John Stultz <john.stultz@xxxxxxxxxx> CommitDate: Mon, 23 Dec 2013 11:54:35 -0800 timekeeping: Fix missing timekeeping_update in suspend path Since 48cdc135d4840 (Implement a shadow timekeeper), we have to call timekeeping_update() after any adjustment to the timekeeping structure in order to make sure that any adjustments to the structure persist. In the timekeeping suspend path, we udpate the timekeeper structure, so we should be sure to update the shadow-timekeeper before releasing the timekeeping locks. Currently this isn't done. In most cases, the next time related code to run would be timekeeping_resume, which does update the shadow-timekeeper, but in an abundence of caution, this patch adds the call to timekeeping_update() in the suspend path. Cc: Sasha Levin <sasha.levin@xxxxxxxxxx> Cc: Thomas Gleixner <tglx@xxxxxxxxxxxxx> Cc: Prarit Bhargava <prarit@xxxxxxxxxx> Cc: Richard Cochran <richardcochran@xxxxxxxxx> Cc: Ingo Molnar <mingo@xxxxxxxxxx> Cc: stable <stable@xxxxxxxxxxxxxxx> #3.10+ Signed-off-by: John Stultz <john.stultz@xxxxxxxxxx> --- kernel/time/timekeeping.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c index 3f6a827..2793c43 100644 --- a/kernel/time/timekeeping.c +++ b/kernel/time/timekeeping.c @@ -1024,6 +1024,8 @@ static int timekeeping_suspend(void) timekeeping_suspend_time = timespec_add(timekeeping_suspend_time, delta_delta); } + + timekeeping_update(tk, TK_MIRROR); write_seqcount_end(&timekeeper_seq); raw_spin_unlock_irqrestore(&timekeeper_lock, flags); -- To unsubscribe from this list: send the line "unsubscribe linux-tip-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html