diff options
author | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | 2021-08-03 16:16:14 +0200 |
---|---|---|
committer | Paul E. McKenney <paulmck@kernel.org> | 2021-08-10 10:47:32 -0700 |
commit | d3dd95a8853f1d588e38e9d9d7c8cc2da412cc36 (patch) | |
tree | fe6ee8c94f8dff0fd0fd1fa8c2d199cb731eb3a7 /kernel | |
parent | 521c89b3a4022269c75b35062358d1dae4ebfa79 (diff) | |
download | linux-stable-d3dd95a8853f1d588e38e9d9d7c8cc2da412cc36.tar.gz linux-stable-d3dd95a8853f1d588e38e9d9d7c8cc2da412cc36.tar.bz2 linux-stable-d3dd95a8853f1d588e38e9d9d7c8cc2da412cc36.zip |
rcu: Replace deprecated CPU-hotplug functions
The functions get_online_cpus() and put_online_cpus() have been
deprecated during the CPU hotplug rework. They map directly to
cpus_read_lock() and cpus_read_unlock().
Replace deprecated CPU-hotplug functions with the official version.
The behavior remains unchanged.
Cc: "Paul E. McKenney" <paulmck@kernel.org>
Cc: Josh Triplett <josh@joshtriplett.org>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Cc: Lai Jiangshan <jiangshanlai@gmail.com>
Cc: Joel Fernandes <joel@joelfernandes.org>
Cc: rcu@vger.kernel.org
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/rcu/tree.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c index 7403328cdf99..f53a3c1bf1d1 100644 --- a/kernel/rcu/tree.c +++ b/kernel/rcu/tree.c @@ -4011,7 +4011,7 @@ void rcu_barrier(void) */ init_completion(&rcu_state.barrier_completion); atomic_set(&rcu_state.barrier_cpu_count, 2); - get_online_cpus(); + cpus_read_lock(); /* * Force each CPU with callbacks to register a new callback. @@ -4042,7 +4042,7 @@ void rcu_barrier(void) rcu_state.barrier_sequence); } } - put_online_cpus(); + cpus_read_unlock(); /* * Now that we have an rcu_barrier_callback() callback on each |