From: Eric W. Biederman Date: Tue, 26 Jul 2005 17:51:06 +0000 (-0600) Subject: [PATCH] Update sysrq-B to use emergency_restart() X-Git-Tag: v2.6.13-rc4~52 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4de8b9b76017365572f778332d74fe050d9c8c2a;p=linux-2.6 [PATCH] Update sysrq-B to use emergency_restart() sysrq calls into the reboot path from an interrupt handler we can either push the code do into process context and call kernel_restart and get a clean reboot or we can simply reboot the machine, and increase our chances of actually rebooting. emergency_reboot() seems like the closest match to what we have previously done, and what we want. Signed-off-by: Eric W. Biederman Signed-off-by: Linus Torvalds --- diff --git a/drivers/char/sysrq.c b/drivers/char/sysrq.c index 12d563c648..feb25158c8 100644 --- a/drivers/char/sysrq.c +++ b/drivers/char/sysrq.c @@ -115,7 +115,7 @@ static void sysrq_handle_reboot(int key, struct pt_regs *pt_regs, struct tty_struct *tty) { local_irq_enable(); - machine_restart(NULL); + emergency_restart(); } static struct sysrq_key_op sysrq_reboot_op = {