commented early_printk patch because of rejects.
[linux-flexiantxendom0-3.2.10.git] / kernel / panic.c
index 10cfaa1..73c45de 100644 (file)
@@ -16,6 +16,7 @@
 #include <linux/init.h>
 #include <linux/sysrq.h>
 #include <linux/interrupt.h>
+#include <linux/nmi.h>
 
 asmlinkage void sys_sync(void);        /* it's really int */
 
@@ -71,12 +72,16 @@ NORET_TYPE void panic(const char * fmt, ...)
 
        if (panic_timeout > 0)
        {
+               int i;
                /*
                 * Delay timeout seconds before rebooting the machine. 
                 * We can't use the "normal" timers since we just panicked..
                 */
                printk(KERN_EMERG "Rebooting in %d seconds..",panic_timeout);
-               mdelay(panic_timeout*1000);
+               for (i = 0; i < panic_timeout; i++) {
+                       touch_nmi_watchdog();
+                       mdelay(1000);
+               }
                /*
                 *      Should we run the reboot notifier. For the moment Im
                 *      choosing not too. It might crash, be corrupt or do