rcu-tasks: Make trc_read_check_handler() fetch ->trc_reader_nesting only once
authorPaul E. McKenney <paulmck@kernel.org>
Thu, 26 May 2022 23:12:51 +0000 (16:12 -0700)
committerPaul E. McKenney <paulmck@kernel.org>
Mon, 20 Jun 2022 16:22:27 +0000 (09:22 -0700)
commit9ff86b4c443cc93bf3a9b624e3385e4114388e85
treeabdd58db04c22386fdc60ae307915b3b9b0941ff
parent550611269b153dc17b44fa2d692c30f628d1c65c
rcu-tasks: Make trc_read_check_handler() fetch ->trc_reader_nesting only once

This commit replaces the pair of READ_ONCE(t->trc_reader_nesting) calls
with a single such call and a local variable.  This makes the code's
intent more clear.

Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
Cc: Neeraj Upadhyay <quic_neeraju@quicinc.com>
Cc: Eric Dumazet <edumazet@google.com>
Cc: Alexei Starovoitov <ast@kernel.org>
Cc: Andrii Nakryiko <andrii@kernel.org>
Cc: Martin KaFai Lau <kafai@fb.com>
Cc: KP Singh <kpsingh@kernel.org>
kernel/rcu/tasks.h