]> www.infradead.org Git - users/jedix/linux-maple.git/commit
rcu-tasks: Make rcu_barrier_tasks*() handle multiple callback queues
authorPaul E. McKenney <paulmck@kernel.org>
Thu, 11 Nov 2021 22:53:43 +0000 (14:53 -0800)
committerPaul E. McKenney <paulmck@kernel.org>
Thu, 9 Dec 2021 18:52:11 +0000 (10:52 -0800)
commitce9b1c667f03e0aa30d3eb69d0932e010d131c49
tree208c1d4391a44cddf0ce54380089227d26b9bc34
parentd363f833c6d88331ff013ff0970a96caa8b84653
rcu-tasks: Make rcu_barrier_tasks*() handle multiple callback queues

Currently, rcu_barrier_tasks(), rcu_barrier_tasks_rude(),
and rcu_barrier_tasks_trace() simply invoke the corresponding
synchronize_rcu_tasks*() function.  This works because there is only
one callback queue.

However, there will soon be multiple callback queues.  This commit
therefore scans the queues currently in use, entraining a callback on
each non-empty queue.  Sequence numbers and reference counts are used
to synchronize this process in a manner similar to the approach taken
by rcu_barrier().

Reported-by: Martin Lau <kafai@fb.com>
Cc: Neeraj Upadhyay <neeraj.iitr10@gmail.com>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
kernel/rcu/tasks.h