rcutorture: Abstract read-lock-held checks
authorPaul E. McKenney <paulmck@kernel.org>
Sun, 14 Mar 2021 04:05:31 +0000 (20:05 -0800)
committerPaul E. McKenney <paulmck@kernel.org>
Mon, 10 May 2021 23:05:05 +0000 (16:05 -0700)
commita5c095e0e9b6fedcffd0907c84f77751128e2a34
treececae0e0ccaf99e42376717a040392dc7d3f14e4
parente9b800db96fa40170c5607d8968b2ec6212c2026
rcutorture: Abstract read-lock-held checks

This commit adds a (*readlock_held)() function pointer to the
rcu_torture_ops structure in order to make the rcu_torture_one_read()
function's rcu_dereference_check() lockdep expression more appropriate
for a given run.

Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
kernel/rcu/rcutorture.c