diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2022-08-25 18:41:24 +0200 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2022-09-19 14:35:07 +0200 |
commit | 555bb4ccd1dd78d0263eae31629fe1fdd65c1fb5 (patch) | |
tree | 88891b9221198fa70d63dc7be7cfa38aa1475318 /README | |
parent | 521a547ced6477c54b4b0cc206000406c221b4d6 (diff) | |
download | linux-555bb4ccd1dd78d0263eae31629fe1fdd65c1fb5.tar.bz2 |
preempt: Provide preempt_[dis|en]able_nested()
On PREEMPT_RT enabled kernels, spinlocks and rwlocks are neither disabling
preemption nor interrupts. Though there are a few places which depend on
the implicit preemption/interrupt disable of those locks, e.g. seqcount
write sections, per CPU statistics updates etc.
To avoid sprinkling CONFIG_PREEMPT_RT conditionals all over the place, add
preempt_disable_nested() and preempt_enable_nested() which should be
descriptive enough.
Add a lockdep assertion for the !PREEMPT_RT case to catch callers which
do not have preemption disabled.
Suggested-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lore.kernel.org/r/20220825164131.402717-2-bigeasy@linutronix.de
Diffstat (limited to 'README')
0 files changed, 0 insertions, 0 deletions