X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=arch%2Fi386%2Fkernel%2Freboot.c;h=3d7e994563df49ee5775255d7f311287d115d4a9;hb=6a77f38946aaee1cd85eeec6cf4229b204c15071;hp=06974254cd92d6160cb643a511b7aa32bd36b80b;hpb=87fc8d1bb10cd459024a742c6a10961fefcef18f;p=linux-2.6.git diff --git a/arch/i386/kernel/reboot.c b/arch/i386/kernel/reboot.c index 06974254c..3d7e99456 100644 --- a/arch/i386/kernel/reboot.c +++ b/arch/i386/kernel/reboot.c @@ -20,7 +20,7 @@ void (*pm_power_off)(void); static int reboot_mode; -int reboot_thru_bios; +static int reboot_thru_bios; #ifdef CONFIG_SMP int reboot_smp = 0; @@ -137,7 +137,7 @@ static struct dmi_system_id __initdata reboot_dmi_table[] = { { } }; -static int reboot_init(void) +static int __init reboot_init(void) { dmi_check_system(reboot_dmi_table); return 0; @@ -331,13 +331,10 @@ void machine_restart(char * __unused) * other OSs see a clean IRQ state. */ smp_send_stop(); -#elif defined(CONFIG_X86_LOCAL_APIC) - if (cpu_has_apic) { - local_irq_disable(); - disable_local_APIC(); - local_irq_enable(); - } -#endif +#endif /* CONFIG_SMP */ + + lapic_shutdown(); + #ifdef CONFIG_X86_IO_APIC disable_IO_APIC(); #endif @@ -373,6 +370,8 @@ EXPORT_SYMBOL(machine_halt); void machine_power_off(void) { + lapic_shutdown(); + if (efi_enabled) efi.reset_system(EFI_RESET_SHUTDOWN, EFI_SUCCESS, 0, NULL); if (pm_power_off)