locktorture: Add acq_writer_lim to complain about long acquistion times
authorPaul E. McKenney <paulmck@kernel.org>
Wed, 2 Aug 2023 23:32:06 +0000 (16:32 -0700)
committerFrederic Weisbecker <frederic@kernel.org>
Sun, 24 Sep 2023 15:24:01 +0000 (17:24 +0200)
commite3bdaefbccbd27b1829414604456611928a5e291
tree8fcac16540b4d839fd85d9e61e19fad0a725ce26
parent84cee9e72e15b65921f05d41788d66a79c1baa25
locktorture: Add acq_writer_lim to complain about long acquistion times

This commit adds a locktorture.acq_writer_lim module parameter that
specifies the maximum number of jiffies that is expected to be consumed
by write-side lock acquisition.  If this limit is exceeded, a WARN_ONCE()
causes a splat.  Note that this limit applies to the main lock acquisition
only, not to any nested acquisitions.

Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
Signed-off-by: Frederic Weisbecker <frederic@kernel.org>
kernel/locking/locktorture.c