Skip to content

Commit da27485

Browse files
Waiman-LongKAGA-KOKO
authored andcommitted
cpu: Remove obsolete comment from takedown_cpu()
takedown_cpu() has a comment about "all preempt/rcu users must observe !cpu_active()" which is kind of meaningless in this function. This comment was originally introduced by commit 6acce3e ("sched: Remove get_online_cpus() usage") when _cpu_down() was setting cpu_active_mask and synchronize_rcu()/synchronize_sched() were added after that. Later commit 40190a7 ("sched/hotplug: Convert cpu_[in]active notifiers to state machine") added a new CPUHP_AP_ACTIVE hotplug state to set/clear cpu_active_mask. The following commit b2454ca ("sched/hotplug: Move sync_rcu to be with set_cpu_active(false)") move the synchronize_*() calls to sched_cpu_deactivate() associated with the new hotplug state, but left the comment behind. Remove this comment as it is no longer relevant in takedown_cpu(). Signed-off-by: Waiman Long <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Link: https://lore.kernel.org/all/[email protected]
1 parent 83e6384 commit da27485

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

kernel/cpu.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1309,9 +1309,6 @@ static int takedown_cpu(unsigned int cpu)
13091309
*/
13101310
irq_lock_sparse();
13111311

1312-
/*
1313-
* So now all preempt/rcu users must observe !cpu_active().
1314-
*/
13151312
err = stop_machine_cpuslocked(take_cpu_down, NULL, cpumask_of(cpu));
13161313
if (err) {
13171314
/* CPU refused to die */

0 commit comments

Comments
 (0)