]> git.baikalelectronics.ru Git - kernel.git/commit
lockdep: Fix lockdep recursion
authorPeter Zijlstra <peterz@infradead.org>
Fri, 2 Oct 2020 09:04:21 +0000 (11:04 +0200)
committerIngo Molnar <mingo@kernel.org>
Fri, 9 Oct 2020 06:53:30 +0000 (08:53 +0200)
commitde412324aec7daf76d6c2fea7dd03c38a3405267
tree9a8023c8fdbe431b9edbbcb2621dbf5c6bb4367b
parent3494cd8fc23560641fa19aaad74ef8fd8c42ebb3
lockdep: Fix lockdep recursion

Steve reported that lockdep_assert*irq*(), when nested inside lockdep
itself, will trigger a false-positive.

One example is the stack-trace code, as called from inside lockdep,
triggering tracing, which in turn calls RCU, which then uses
lockdep_assert_irqs_disabled().

Fixes: fe91c8983ebe ("lockdep: Change hardirq{s_enabled,_context} to per-cpu variables")
Reported-by: Steven Rostedt <rostedt@goodmis.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
include/linux/lockdep.h
kernel/locking/lockdep.c