set_cpus_allowed is not safe in interrupt context
and disabling apics is complicated code so don't
call machine_shutdown on i386 from emergency_restart().
Signed-off-by: Eric W. Biederman <[email protected]>
---
arch/i386/kernel/reboot.c | 10 +++++++---
include/asm-i386/emergency-restart.h | 2 +-
2 files changed, 8 insertions(+), 4 deletions(-)
fcfe4ee919b83e5002dd696a94834fd3ccb31be8
diff --git a/arch/i386/kernel/reboot.c b/arch/i386/kernel/reboot.c
--- a/arch/i386/kernel/reboot.c
+++ b/arch/i386/kernel/reboot.c
@@ -311,10 +311,8 @@ void machine_shutdown(void)
#endif
}
-void machine_restart(char * __unused)
+void machine_emergency_restart(void)
{
- machine_shutdown();
-
if (!reboot_thru_bios) {
if (efi_enabled) {
efi.reset_system(EFI_RESET_COLD, EFI_SUCCESS, 0, NULL);
@@ -337,6 +335,12 @@ void machine_restart(char * __unused)
machine_real_restart(jump_to_bios, sizeof(jump_to_bios));
}
+void machine_restart(char * __unused)
+{
+ machine_shutdown();
+ machine_emergency_restart();
+}
+
void machine_halt(void)
{
}
diff --git a/include/asm-i386/emergency-restart.h b/include/asm-i386/emergency-restart.h
--- a/include/asm-i386/emergency-restart.h
+++ b/include/asm-i386/emergency-restart.h
@@ -1,6 +1,6 @@
#ifndef _ASM_EMERGENCY_RESTART_H
#define _ASM_EMERGENCY_RESTART_H
-#include <asm-generic/emergency-restart.h>
+extern void machine_emergency_restart(void);
#endif /* _ASM_EMERGENCY_RESTART_H */
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
|
|