hrtimer: Ignore slack time for RT tasks in schedule_hrtimeout_range()
authorDavidlohr Bueso <dave@stgolabs.net>
Mon, 23 Jan 2023 17:32:06 +0000 (09:32 -0800)
committerThomas Gleixner <tglx@linutronix.de>
Tue, 31 Jan 2023 10:23:07 +0000 (11:23 +0100)
commit0c52310f260014d95c1310364379772cb74cf82d
tree09732bb44aee542de2ec36497fd7f0a62d7171c9
parentc14fd3dcacaa480394d3ac0b4a91a7d17a4b5516
hrtimer: Ignore slack time for RT tasks in schedule_hrtimeout_range()

While in theory the timer can be triggered before expires + delta, for the
cases of RT tasks they really have no business giving any lenience for
extra slack time, so override any passed value by the user and always use
zero for schedule_hrtimeout_range() calls. Furthermore, this is similar to
what the nanosleep(2) family already does with current->timer_slack_ns.

Signed-off-by: Davidlohr Bueso <dave@stgolabs.net>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lore.kernel.org/r/20230123173206.6764-3-dave@stgolabs.net
kernel/time/hrtimer.c