diff options
author | Shawn Guo <shawn.guo@linaro.org> | 2012-10-04 17:12:23 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-10-13 05:38:38 +0900 |
commit | 3fc49ce67fefd3de38aa72a215eb1a2b68a7e89b (patch) | |
tree | 2fc96ba798b7a8d014adcbcd7dbcdb2d93ca6d51 /kernel | |
parent | 6d36a9dd1dcdd053ab32f303b94cc1bae5a47f22 (diff) |
kernel/sys.c: call disable_nonboot_cpus() in kernel_restart()
commit f96972f2dc6365421cf2366ebd61ee4cf060c8d5 upstream.
As kernel_power_off() calls disable_nonboot_cpus(), we may also want to
have kernel_restart() call disable_nonboot_cpus(). Doing so can help
machines that require boot cpu be the last alive cpu during reboot to
survive with kernel restart.
This fixes one reboot issue seen on imx6q (Cortex-A9 Quad). The machine
requires that the restart routine be run on the primary cpu rather than
secondary ones. Otherwise, the secondary core running the restart
routine will fail to come to online after reboot.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/sys.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/sys.c b/kernel/sys.c index e7006eb6c1e4..898a84c9df5b 100644 --- a/kernel/sys.c +++ b/kernel/sys.c @@ -365,6 +365,7 @@ EXPORT_SYMBOL(unregister_reboot_notifier); void kernel_restart(char *cmd) { kernel_restart_prepare(cmd); + disable_nonboot_cpus(); if (!cmd) printk(KERN_EMERG "Restarting system.\n"); else |