diff options
author | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2012-06-27 02:00:35 +0200 |
---|---|---|
committer | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2012-09-23 16:41:54 +0200 |
commit | 394f2769aa0dbcf027bae6fb52835e25e05d332e (patch) | |
tree | 78471127d379e8d128d73e976ce33022c195b0c5 /kernel/rcutree.h | |
parent | rcu: Adjust debugfs tracing for kthread-based quiescent-state forcing (diff) | |
download | linux-394f2769aa0dbcf027bae6fb52835e25e05d332e.tar.xz linux-394f2769aa0dbcf027bae6fb52835e25e05d332e.zip |
rcu: Prevent force_quiescent_state() memory contention
Large systems running RCU_FAST_NO_HZ kernels see extreme memory
contention on the rcu_state structure's ->fqslock field. This
can be avoided by disabling RCU_FAST_NO_HZ, either at compile time
or at boot time (via the nohz kernel boot parameter), but large
systems will no doubt become sensitive to energy consumption.
This commit therefore uses a combining-tree approach to spread the
memory contention across new cache lines in the leaf rcu_node structures.
This can be thought of as a tournament lock that has only a try-lock
acquisition primitive.
The effect on small systems is minimal, because such systems have
an rcu_node "tree" consisting of a single node. In addition, this
functionality is not used on fastpaths.
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Diffstat (limited to 'kernel/rcutree.h')
-rw-r--r-- | kernel/rcutree.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/rcutree.h b/kernel/rcutree.h index 7fb93cedc76a..8f0293ce1517 100644 --- a/kernel/rcutree.h +++ b/kernel/rcutree.h @@ -202,6 +202,7 @@ struct rcu_node { /* per-CPU kthreads as needed. */ unsigned int node_kthread_status; /* State of node_kthread_task for tracing. */ + raw_spinlock_t fqslock ____cacheline_internodealigned_in_smp; } ____cacheline_internodealigned_in_smp; /* |