[POWERPC] pasemi: Move cpus to hold loop before restart
authorOlof Johansson <olof@lixom.net>
Wed, 7 Nov 2007 15:31:06 +0000 (09:31 -0600)
committerOlof Johansson <olof@lixom.net>
Sat, 1 Dec 2007 19:04:39 +0000 (13:04 -0600)
Use smp_send_stop() to move all cpus besides the one executing reboot
into a hold loop, to keep them from being in powersavings mode at the
time of reboot.

Signed-off-by: Olof Johansson <olof@lixom.net>
arch/powerpc/platforms/pasemi/setup.c

index bd85853..2b63865 100644 (file)
 
 #include "pasemi.h"
 
+#if !defined(CONFIG_SMP)
+static void smp_send_stop(void) {}
+#endif
+
 /* SDC reset register, must be pre-mapped at reset time */
 static void __iomem *reset_reg;
 
@@ -60,6 +64,9 @@ static int num_mce_regs;
 
 static void pas_restart(char *cmd)
 {
+       /* Need to put others cpu in hold loop so they're not sleeping */
+       smp_send_stop();
+       udelay(10000);
        printk("Restarting...\n");
        while (1)
                out_le32(reset_reg, 0x6000000);