aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/stackleak.c
diff options
context:
space:
mode:
authorSebastian Andrzej Siewior <bigeasy@linutronix.de>2019-07-26 20:30:58 +0200
committerThomas Gleixner <tglx@linutronix.de>2019-08-01 20:51:22 +0200
commit1842f5a427f5323f5c19ab99b55d09b3ab5172a5 (patch)
tree273a4d23da40d208ed187f09ae9c9a0007b2b35e /kernel/stackleak.c
parenthrtimer: Move unmarked hrtimers to soft interrupt expiry on RT (diff)
downloadlinux-dev-1842f5a427f5323f5c19ab99b55d09b3ab5172a5.tar.xz
linux-dev-1842f5a427f5323f5c19ab99b55d09b3ab5172a5.zip
hrtimer: Determine hard/soft expiry mode for hrtimer sleepers on RT
On PREEMPT_RT enabled kernels hrtimers which are not explicitely marked for hard interrupt expiry mode are moved into soft interrupt context either for latency reasons or because the hrtimer callback takes regular spinlocks or invokes other functions which are not suitable for hard interrupt context on PREEMPT_RT. The hrtimer_sleeper callback is RT compatible in hard interrupt context, but there is a latency concern: Untrusted userspace can spawn many threads which arm timers for the same expiry time on the same CPU. On expiry that causes a latency spike due to the wakeup of a gazillion threads. OTOH, priviledged real-time user space applications rely on the low latency of hard interrupt wakeups. These syscall related wakeups are all based on hrtimer sleepers. If the current task is in a real-time scheduling class, mark the mode for hard interrupt expiry. [ tglx: Split out of a larger combo patch. Added changelog ] Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Steven Rostedt (VMware) <rostedt@goodmis.org> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Link: https://lkml.kernel.org/r/20190726185753.645792403@linutronix.de
Diffstat (limited to 'kernel/stackleak.c')
0 files changed, 0 insertions, 0 deletions