From cea6a4ba8acfba6f59cc9ed71e0d05cb770b9d9c Mon Sep 17 00:00:00 2001 From: Horms Date: Sun, 30 Jul 2006 03:03:34 -0700 Subject: [PATCH] panic_on_oops: remove ssleep() This patch is part of an effort to unify the panic_on_oops behaviour across all architectures that implement it. It was pointed out to me by Andi Kleen that if an oops has occured in interrupt context, then calling sleep() in the oops path will only cause a panic, and that it would be really better for it not to be in the path at all. This patch removes the ssleep() call and reworks the console message accordinly. I have a slght concern that the resulting console message is too long, feedback welcome. For powerpc it also unifies the 32bit and 64bit behaviour. Fror x86_64, this patch only updates the console message, as ssleep() is already not present. Signed-off-by: Horms Acked-by: Paul Mackerras Cc: Russell King Cc: "Luck, Tony" Cc: Andi Kleen Cc: Chris Zankel Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- arch/xtensa/kernel/traps.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'arch/xtensa') diff --git a/arch/xtensa/kernel/traps.c b/arch/xtensa/kernel/traps.c index 27e409089a7..9734960a245 100644 --- a/arch/xtensa/kernel/traps.c +++ b/arch/xtensa/kernel/traps.c @@ -487,11 +487,9 @@ void die(const char * str, struct pt_regs * regs, long err) if (in_interrupt()) panic("Fatal exception in interrupt"); - if (panic_on_oops) { - printk(KERN_EMERG "Fatal exception: panic in 5 seconds\n"); - ssleep(5); - panic("Fatal exception"); - } + if (panic_on_oops) + panic("Fatal exception: panic_on_oops"); + do_exit(err); } -- cgit v1.2.3