rcu-tasks: Split ->trc_reader_need_end
authorPaul E. McKenney <paulmck@kernel.org>
Tue, 17 Mar 2020 23:02:06 +0000 (16:02 -0700)
committerPaul E. McKenney <paulmck@kernel.org>
Mon, 27 Apr 2020 18:03:52 +0000 (11:03 -0700)
commit276c410448dbca357a2bc3539acfe04862e5f172
tree5f25b125fb10b79997286884b3724f5415eb5b11
parentb0afa0f056676ffe0a7213818f09d2460adbcc16
rcu-tasks: Split ->trc_reader_need_end

This commit splits ->trc_reader_need_end by using the rcu_special union.
This change permits readers to check to see if a memory barrier is
required without any added overhead in the common case where no such
barrier is required.  This commit also adds the read-side checking.
Later commits will add the machinery to properly set the new
->trc_reader_special.b.need_mb field.

This commit also makes rcu_read_unlock_trace_special() tolerate nested
read-side critical sections within interrupt and NMI handlers.

Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
include/linux/rcupdate_trace.h
include/linux/sched.h
init/init_task.c
kernel/fork.c
kernel/rcu/tasks.h