From 1001d0a9ee74a468077dfd4da0565174e88de26b Mon Sep 17 00:00:00 2001 From: Thomas Gleixner Date: Fri, 1 Feb 2008 17:45:13 +0100 Subject: timekeeping: update xtime_cache when time(zone) changes xtime_cache needs to be updated whenever xtime and or wall_to_monotic are changed. Otherwise users of xtime_cache might see a stale (and in the case of timezone changes utterly wrong) value until the next update happens. Fixup the obvious places, which miss this update. Signed-off-by: Thomas Gleixner Acked-by: John Stultz Tested-by: Dhaval Giani Signed-off-by: Ingo Molnar --- kernel/time.c | 1 + 1 file changed, 1 insertion(+) (limited to 'kernel/time.c') diff --git a/kernel/time.c b/kernel/time.c index 09d3c45c4da..4064c0566e7 100644 --- a/kernel/time.c +++ b/kernel/time.c @@ -129,6 +129,7 @@ static inline void warp_clock(void) write_seqlock_irq(&xtime_lock); wall_to_monotonic.tv_sec -= sys_tz.tz_minuteswest * 60; xtime.tv_sec += sys_tz.tz_minuteswest * 60; + update_xtime_cache(0); write_sequnlock_irq(&xtime_lock); clock_was_set(); } -- cgit v1.2.3