diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-12-11 22:56:33 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-12-11 22:56:33 -0500 |
commit | 74b84233458e9db7c160cec67638efdbec748ca9 (patch) | |
tree | 0d174c7386386dca17f494396d7febc300ffa3dd /kernel/cpu.c | |
parent | 507447473756e316f3f182324071389a51736a83 (diff) | |
parent | a71c8bc5dfefbbf80ef90739791554ef7ea4401b (diff) |
Merge branch 'x86-bsp-hotplug-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull x86 BSP hotplug changes from Ingo Molnar:
"This tree enables CPU#0 (the boot processor) to be onlined/offlined on
x86, just like any other CPU. Enabled on Intel CPUs for now.
Allowing this required the identification and fixing of latent CPU#0
assumptions (such as CPU#0 initializations, etc.) in the x86
architecture code, plus the identification of barriers to
BSP-offlining, such as active PIC interrupts which can only be
serviced on the BSP.
It's behind a default-off option, and there's a debug option that
allows the automatic testing of this feature.
The motivation of this feature is to allow and prepare for true
CPU-hotplug hardware support: recent changes to MCE support enable us
to detect a deteriorating but not yet hard-failing L1/L2 cache on a
CPU that could be soft-unplugged - or a failing L3 cache on a
multi-socket system.
Note that true hardware hot-plug is not yet fully enabled by this,
because that requires a special platform wakeup sequence to be sent to
the freshly powered up CPU#0. Future patches for this are planned,
once such a platform exists. Chicken and egg"
* 'x86-bsp-hotplug-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
x86, topology: Debug CPU0 hotplug
x86/i387.c: Initialize thread xstate only on CPU0 only once
x86, hotplug: Handle retrigger irq by the first available CPU
x86, hotplug: The first online processor saves the MTRR state
x86, hotplug: During CPU0 online, enable x2apic, set_numa_node.
x86, hotplug: Wake up CPU0 via NMI instead of INIT, SIPI, SIPI
x86-32, hotplug: Add start_cpu0() entry point to head_32.S
x86-64, hotplug: Add start_cpu0() entry point to head_64.S
kernel/cpu.c: Add comment for priority in cpu_hotplug_pm_callback
x86, hotplug, suspend: Online CPU0 for suspend or hibernate
x86, hotplug: Support functions for CPU0 online/offline
x86, topology: Don't offline CPU0 if any PIC irq can not be migrated out of it
x86, Kconfig: Add config switch for CPU0 hotplug
doc: Add x86 CPU0 online/offline feature
Diffstat (limited to 'kernel/cpu.c')
-rw-r--r-- | kernel/cpu.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/kernel/cpu.c b/kernel/cpu.c index f45657f1eb8e..3046a503242c 100644 --- a/kernel/cpu.c +++ b/kernel/cpu.c | |||
@@ -603,6 +603,11 @@ cpu_hotplug_pm_callback(struct notifier_block *nb, | |||
603 | 603 | ||
604 | static int __init cpu_hotplug_pm_sync_init(void) | 604 | static int __init cpu_hotplug_pm_sync_init(void) |
605 | { | 605 | { |
606 | /* | ||
607 | * cpu_hotplug_pm_callback has higher priority than x86 | ||
608 | * bsp_pm_callback which depends on cpu_hotplug_pm_callback | ||
609 | * to disable cpu hotplug to avoid cpu hotplug race. | ||
610 | */ | ||
606 | pm_notifier(cpu_hotplug_pm_callback, 0); | 611 | pm_notifier(cpu_hotplug_pm_callback, 0); |
607 | return 0; | 612 | return 0; |
608 | } | 613 | } |