From 19c9bba94152148523ba0f7ef7cffe3d45656b11 Mon Sep 17 00:00:00 2001 From: Ralf Baechle Date: Tue, 29 Apr 1997 21:13:14 +0000 Subject: Import of Linux/MIPS 2.1.36 --- kernel/panic.c | 29 ++++++++++++++++++----------- 1 file changed, 18 insertions(+), 11 deletions(-) (limited to 'kernel/panic.c') diff --git a/kernel/panic.c b/kernel/panic.c index d42541e9f..deaa2f339 100644 --- a/kernel/panic.c +++ b/kernel/panic.c @@ -10,15 +10,16 @@ */ #include -#include #include #include #include +#include +#include #include asmlinkage void sys_sync(void); /* it's really int */ -extern void do_unblank_screen(void); +extern void unblank_console(void); extern int C_A_D; int panic_timeout = 0; @@ -43,9 +44,12 @@ NORET_TYPE void panic(const char * fmt, ...) else sys_sync(); - do_unblank_screen(); +#ifdef __SMP__ + smp_message_pass(MSG_ALL_BUT_SELF, MSG_STOP_CPU, 0, 0); +#endif + + unblank_console(); -#ifdef CONFIG_SGI if (panic_timeout > 0) { int i; @@ -54,17 +58,20 @@ NORET_TYPE void panic(const char * fmt, ...) * Delay timeout seconds before rebooting the machine. * We can't use the "normal" timers since we just panicked.. */ - prom_printf(KERN_EMERG "Rebooting in %d seconds..",panic_timeout); + printk(KERN_EMERG "Rebooting in %d seconds..",panic_timeout); for(i = 0; i < (panic_timeout*1000); i++) udelay(1000); - hard_reset_now(); + /* + * Should we run the reboot notifier. For the moment Im + * choosing not too. It might crash, be corrupt or do + * more harm than good for other reasons. + */ + machine_restart(NULL); } -#if 0 - printk("Hit a key\n"); - prom_getchar(); - romvec->imode(); -#endif +#ifdef __sparc__ + printk("Press L1-A to return to the boot prom\n"); #endif + sti(); for(;;); } -- cgit v1.2.3