Commit 82584ef7 authored by Shaohua Li's avatar Shaohua Li Committed by Linus Torvalds

[PATCH] x86: fix NMI with CPU hotplug

With CPU hotplug enabled, NMI watchdog stoped working.  It appears the
violation is the cpu_online check in nmi handler.  local ACPI based NMI
watchdog is initialized before we set CPU online for APs.  It's quite
possible a NMI is fired before we set CPU online, and that's what happens
here.
Signed-off-by: default avatarShaohua Li <shaohua.li@intel.com>
Acked-by: default avatarZwane Mwaikambo <zwane@arm.linux.org.uk>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent b3e55c72
...@@ -650,13 +650,6 @@ fastcall void do_nmi(struct pt_regs * regs, long error_code) ...@@ -650,13 +650,6 @@ fastcall void do_nmi(struct pt_regs * regs, long error_code)
cpu = smp_processor_id(); cpu = smp_processor_id();
#ifdef CONFIG_HOTPLUG_CPU
if (!cpu_online(cpu)) {
nmi_exit();
return;
}
#endif
++nmi_count(cpu); ++nmi_count(cpu);
if (!rcu_dereference(nmi_callback)(regs, cpu)) if (!rcu_dereference(nmi_callback)(regs, cpu))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment