]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
srcu: Permit Tiny SRCU srcu_read_unlock() with interrupts disabled
authorPaul E. McKenney <paulmck@kernel.org>
Wed, 5 Nov 2025 20:32:01 +0000 (12:32 -0800)
committerFrederic Weisbecker <frederic@kernel.org>
Wed, 5 Nov 2025 22:58:11 +0000 (23:58 +0100)
commit58ac42f278054fbc4c3f174524280d7263b0699a
treece58f07806a977d70a6f3743f5a52545174c4d4e
parent3a8660878839faadb4f1a6dd72c3179c1df56787
srcu: Permit Tiny SRCU srcu_read_unlock() with interrupts disabled

The current Tiny SRCU implementation of srcu_read_unlock() awakens
the grace-period processing when exiting the outermost SRCU read-side
critical section.  However, not all Linux-kernel configurations and
contexts permit swake_up_one() to be invoked while interrupts are
disabled, and this can result in indefinitely extended SRCU grace periods.
This commit therefore only invokes swake_up_one() when interrupts are
enabled, and introduces polling to the grace-period workqueue handler.

Reported-by: kernel test robot <oliver.sang@intel.com>
Reported-by: Zqiang <qiang.zhang@linux.dev>
Closes: https://lore.kernel.org/oe-lkp/202508261642.b15eefbb-lkp@intel.com
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
Signed-off-by: Frederic Weisbecker <frederic@kernel.org>
kernel/rcu/srcutiny.c