diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2008-09-22 16:56:01 (GMT) |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2008-09-23 09:38:53 (GMT) |
commit | 49d670fb8dd62d3ed4e3ed2513538ea65b051aed (patch) | |
tree | 7d571897b5407abc25b776d4738e4af3ea0a5940 | |
parent | 4faac97d44ac27bdbb010a9c3597401a8f89341f (diff) | |
download | linux-49d670fb8dd62d3ed4e3ed2513538ea65b051aed.tar.xz |
clockevents: prevent stale tick_next_period for onlining CPUs
Impact: possible hang on CPU onlining in timer one shot mode.
The tick_next_period variable is only used during boot on nohz/highres
enabled systems, but for CPU onlining it needs to be maintained when
the per cpu clock events device operates in one shot mode.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
-rw-r--r-- | kernel/time/tick-sched.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/kernel/time/tick-sched.c b/kernel/time/tick-sched.c index 31a14e8..39019b3f 100644 --- a/kernel/time/tick-sched.c +++ b/kernel/time/tick-sched.c @@ -75,6 +75,9 @@ static void tick_do_update_jiffies64(ktime_t now) incr * ticks); } do_timer(++ticks); + + /* Keep the tick_next_period variable up to date */ + tick_next_period = ktime_add(last_jiffies_update, tick_period); } write_sequnlock(&xtime_lock); } |