Skip to content
Commit f042a436 authored by Paul E. McKenney's avatar Paul E. McKenney
Browse files

rcutorture: Add READ_ONCE() to rcu_torture_count and rcu_torture_batch



The rcutorture rcu_torture_count and rcu_torture_batch per-CPU variables
are read locklessly, so this commit adds the READ_ONCE() to a load in
order to avoid various types of compiler vandalism^Woptimization.

This data race was reported by KCSAN. Not appropriate for backporting
due to failure being unlikely and due to this being rcutorture.

Signed-off-by: default avatarPaul E. McKenney <paulmck@kernel.org>
parent 102c14d2
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment