diff options
Diffstat (limited to 'arch/i386')
-rw-r--r-- | arch/i386/kernel/smpboot.c | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/arch/i386/kernel/smpboot.c b/arch/i386/kernel/smpboot.c index 9b0dd2744c82..4ff55e675576 100644 --- a/arch/i386/kernel/smpboot.c +++ b/arch/i386/kernel/smpboot.c | |||
@@ -45,6 +45,7 @@ | |||
45 | #include <linux/notifier.h> | 45 | #include <linux/notifier.h> |
46 | #include <linux/cpu.h> | 46 | #include <linux/cpu.h> |
47 | #include <linux/percpu.h> | 47 | #include <linux/percpu.h> |
48 | #include <linux/nmi.h> | ||
48 | 49 | ||
49 | #include <linux/delay.h> | 50 | #include <linux/delay.h> |
50 | #include <linux/mc146818rtc.h> | 51 | #include <linux/mc146818rtc.h> |
@@ -1278,8 +1279,9 @@ void __cpu_die(unsigned int cpu) | |||
1278 | 1279 | ||
1279 | int __cpuinit __cpu_up(unsigned int cpu) | 1280 | int __cpuinit __cpu_up(unsigned int cpu) |
1280 | { | 1281 | { |
1282 | unsigned long flags; | ||
1281 | #ifdef CONFIG_HOTPLUG_CPU | 1283 | #ifdef CONFIG_HOTPLUG_CPU |
1282 | int ret=0; | 1284 | int ret = 0; |
1283 | 1285 | ||
1284 | /* | 1286 | /* |
1285 | * We do warm boot only on cpus that had booted earlier | 1287 | * We do warm boot only on cpus that had booted earlier |
@@ -1297,23 +1299,25 @@ int __cpuinit __cpu_up(unsigned int cpu) | |||
1297 | /* In case one didn't come up */ | 1299 | /* In case one didn't come up */ |
1298 | if (!cpu_isset(cpu, cpu_callin_map)) { | 1300 | if (!cpu_isset(cpu, cpu_callin_map)) { |
1299 | printk(KERN_DEBUG "skipping cpu%d, didn't come online\n", cpu); | 1301 | printk(KERN_DEBUG "skipping cpu%d, didn't come online\n", cpu); |
1300 | local_irq_enable(); | ||
1301 | return -EIO; | 1302 | return -EIO; |
1302 | } | 1303 | } |
1303 | 1304 | ||
1304 | local_irq_enable(); | ||
1305 | |||
1306 | per_cpu(cpu_state, cpu) = CPU_UP_PREPARE; | 1305 | per_cpu(cpu_state, cpu) = CPU_UP_PREPARE; |
1307 | /* Unleash the CPU! */ | 1306 | /* Unleash the CPU! */ |
1308 | cpu_set(cpu, smp_commenced_mask); | 1307 | cpu_set(cpu, smp_commenced_mask); |
1309 | 1308 | ||
1310 | /* | 1309 | /* |
1311 | * Check TSC synchronization with the AP: | 1310 | * Check TSC synchronization with the AP (keep irqs disabled |
1311 | * while doing so): | ||
1312 | */ | 1312 | */ |
1313 | local_irq_save(flags); | ||
1313 | check_tsc_sync_source(cpu); | 1314 | check_tsc_sync_source(cpu); |
1315 | local_irq_restore(flags); | ||
1314 | 1316 | ||
1315 | while (!cpu_isset(cpu, cpu_online_map)) | 1317 | while (!cpu_isset(cpu, cpu_online_map)) { |
1316 | cpu_relax(); | 1318 | cpu_relax(); |
1319 | touch_nmi_watchdog(); | ||
1320 | } | ||
1317 | 1321 | ||
1318 | #ifdef CONFIG_X86_GENERICARCH | 1322 | #ifdef CONFIG_X86_GENERICARCH |
1319 | if (num_online_cpus() > 8 && genapic == &apic_default) | 1323 | if (num_online_cpus() > 8 && genapic == &apic_default) |