diff options
author | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2014-05-09 21:06:51 -0400 |
---|---|---|
committer | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2014-07-09 12:14:35 -0400 |
commit | 4da117cfa72e6cde3d9e8f5ed932381863cdeec9 (patch) | |
tree | 4237aebb9bb34f6599904396d69a9818e8587b17 | |
parent | b4426b49c65e0d266f8a9181ca51d5bf11407714 (diff) |
rcu: Remove redundant ACCESS_ONCE() from tick_do_timer_cpu
In kernels built with CONFIG_NO_HZ_FULL, tick_do_timer_cpu is constant
once boot completes. Thus, there is no need to wrap it in ACCESS_ONCE()
in code that is built only when CONFIG_NO_HZ_FULL. This commit therefore
removes the redundant ACCESS_ONCE().
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Acked-by: Frederic Weisbecker <fweisbec@gmail.com>
Reviewed-by: Lai Jiangshan <laijs@cn.fujitsu.com>
-rw-r--r-- | kernel/rcu/tree_plugin.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/rcu/tree_plugin.h b/kernel/rcu/tree_plugin.h index 02ac0fb186b8..5da9f9b3abc9 100644 --- a/kernel/rcu/tree_plugin.h +++ b/kernel/rcu/tree_plugin.h | |||
@@ -2844,7 +2844,7 @@ static bool rcu_nohz_full_cpu(struct rcu_state *rsp) | |||
2844 | static void rcu_bind_gp_kthread(void) | 2844 | static void rcu_bind_gp_kthread(void) |
2845 | { | 2845 | { |
2846 | #ifdef CONFIG_NO_HZ_FULL | 2846 | #ifdef CONFIG_NO_HZ_FULL |
2847 | int cpu = ACCESS_ONCE(tick_do_timer_cpu); | 2847 | int cpu = tick_do_timer_cpu; |
2848 | 2848 | ||
2849 | if (cpu < 0 || cpu >= nr_cpu_ids) | 2849 | if (cpu < 0 || cpu >= nr_cpu_ids) |
2850 | return; | 2850 | return; |