hrtimer: Unbreak hrtimer_force_reprogram()
authorThomas Gleixner <tglx@linutronix.de>
Thu, 12 Aug 2021 20:32:30 +0000 (22:32 +0200)
committerThomas Gleixner <tglx@linutronix.de>
Thu, 12 Aug 2021 20:34:40 +0000 (22:34 +0200)
commitf80e21489590c00f46226d5802d900e6f66e5633
treebe70538430e3c05e1ce5e1ecd950b4b7c690729a
parent9482fd71dbb8f0d1a61821a83e467dc0a9d7b429
hrtimer: Unbreak hrtimer_force_reprogram()

Since the recent consoliation of reprogramming functions,
hrtimer_force_reprogram() is affected by a check whether the new expiry
time is past the current expiry time.

This breaks the NOHZ logic as that relies on the fact that the tick hrtimer
is moved into the future. That means cpu_base->expires_next becomes stale
and subsequent reprogramming attempts fail as well until the situation is
cleaned up by an hrtimer interrupts.

For some yet unknown reason this leads to a complete stall, so for now
partially revert the offending commit to a known working state. The root
cause for the stall is still investigated and will be fixed in a subsequent
commit.

Fixes: b14bca97c9f5 ("hrtimer: Consolidate reprogramming code")
Reported-by: Mike Galbraith <efault@gmx.de>
Reported-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Tested-by: Mike Galbraith <efault@gmx.de>
Link: https://lore.kernel.org/r/8735recskh.ffs@tglx
kernel/time/hrtimer.c