lockdep: Add assertion to check if in an interrupt
authorJoel Fernandes (Google) <joel@joelfernandes.org>
Tue, 26 Mar 2019 19:24:08 +0000 (15:24 -0400)
committerPaul E. McKenney <paulmck@linux.ibm.com>
Sat, 25 May 2019 21:50:51 +0000 (14:50 -0700)
commit71d8d1531e0904e08adf1540e191bd707dfd73da
treeda3f98b572f2dbac7fdc10c1237d4e1834108baf
parente015a341122024198f57d1f0498a776523137e94
lockdep: Add assertion to check if in an interrupt

In rcu_rrupt_from_idle, we want to check if it is called from within an
interrupt, but want to do such checking only for debug builds. lockdep
already tracks when we enter an interrupt. Let us expose it as an
assertion macro so it can be used to assert this.

Suggested-by: Steven Rostedt <rostedt@goodmis.org>
Cc: kernel-team@android.com
Cc: rcu@vger.kernel.org
Signed-off-by: Joel Fernandes (Google) <joel@joelfernandes.org>
Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
include/linux/lockdep.h