]> git.baikalelectronics.ru Git - kernel.git/commit
rcu-tasks: Remove preemption disablement around srcu_read_[un]lock() calls
authorFrederic Weisbecker <frederic@kernel.org>
Fri, 25 Nov 2022 13:54:59 +0000 (14:54 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 10 Mar 2023 08:32:51 +0000 (09:32 +0100)
commit0f14e3d3563cd785b0d9a6d5ca97357119d3772f
tree773cbfaba670970a5ed94ade64a812eac9813635
parentd5a9c95f7bc10afe563497616382ccb522935ee2
rcu-tasks: Remove preemption disablement around srcu_read_[un]lock() calls

[ Upstream commit 95f24700c88b2b60b3e5f2b534a390e94d7495e7 ]

Ever since the following commit:

28ec03e8010a ("srcu: Simplify __srcu_read_unlock() via this_cpu_dec()")

SRCU doesn't rely anymore on preemption to be disabled in order to
modify the per-CPU counter. And even then it used to be done from the API
itself.

Therefore and after checking further, it appears to be safe to remove
the preemption disablement around __srcu_read_[un]lock() in
exit_tasks_rcu_start() and exit_tasks_rcu_finish()

Suggested-by: Boqun Feng <boqun.feng@gmail.com>
Suggested-by: Paul E. McKenney <paulmck@kernel.org>
Suggested-by: Neeraj Upadhyay <quic_neeraju@quicinc.com>
Cc: Lai Jiangshan <jiangshanlai@gmail.com>
Signed-off-by: Frederic Weisbecker <frederic@kernel.org>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
Stable-dep-of: 96de5a1178bc ("rcu-tasks: Fix synchronize_rcu_tasks() VS zap_pid_ns_processes()")
Signed-off-by: Sasha Levin <sashal@kernel.org>
kernel/rcu/tasks.h