Skip to content

Commit 31ba04d

Browse files
committed
Merge branch 'smp-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull SMP fix from Thomas Gleixner: "Replace the bogus BUG_ON in the cpu hotplug code" * 'smp-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: smp/hotplug: Replace BUG_ON and react useful
2 parents 338a57d + dea1d0f commit 31ba04d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

kernel/cpu.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -279,7 +279,8 @@ static int bringup_wait_for_ap(unsigned int cpu)
279279

280280
/* Wait for the CPU to reach CPUHP_AP_ONLINE_IDLE */
281281
wait_for_completion(&st->done);
282-
BUG_ON(!cpu_online(cpu));
282+
if (WARN_ON_ONCE((!cpu_online(cpu))))
283+
return -ECANCELED;
283284

284285
/* Unpark the stopper thread and the hotplug thread of the target cpu */
285286
stop_machine_unpark(cpu);

0 commit comments

Comments
 (0)