timers: Forward the wheel clock whenever possible
authorThomas Gleixner <tglx@linutronix.de>
Mon, 4 Jul 2016 09:50:36 +0000 (09:50 +0000)
committerIngo Molnar <mingo@kernel.org>
Thu, 7 Jul 2016 08:35:11 +0000 (10:35 +0200)
commita683f390b93f4d1292f849fc48d28e322046120f
treede6367ae59e62bad9135eeff3b35512158e335e5
parentff00673292bd42a3688b33de47252a6a3c3f424c
timers: Forward the wheel clock whenever possible

The wheel clock is stale when a CPU goes into a long idle sleep. This has the
side effect that timers which are queued end up in the outer wheel levels.
That results in coarser granularity.

To solve this, we keep track of the idle state and forward the wheel clock
whenever possible.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Arjan van de Ven <arjan@infradead.org>
Cc: Chris Mason <clm@fb.com>
Cc: Eric Dumazet <edumazet@google.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: George Spelvin <linux@sciencehorizons.net>
Cc: Josh Triplett <josh@joshtriplett.org>
Cc: Len Brown <lenb@kernel.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Rik van Riel <riel@redhat.com>
Cc: rt@linutronix.de
Link: http://lkml.kernel.org/r/20160704094342.512039360@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
kernel/time/tick-internal.h
kernel/time/tick-sched.c
kernel/time/timer.c