diff options
Diffstat (limited to 'arch/mips/kernel/traps.c')
-rw-r--r-- | arch/mips/kernel/traps.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/mips/kernel/traps.c b/arch/mips/kernel/traps.c index 954a198494ef..368fdb779175 100644 --- a/arch/mips/kernel/traps.c +++ b/arch/mips/kernel/traps.c | |||
@@ -20,6 +20,7 @@ | |||
20 | #include <linux/spinlock.h> | 20 | #include <linux/spinlock.h> |
21 | #include <linux/kallsyms.h> | 21 | #include <linux/kallsyms.h> |
22 | #include <linux/bootmem.h> | 22 | #include <linux/bootmem.h> |
23 | #include <linux/interrupt.h> | ||
23 | 24 | ||
24 | #include <asm/bootinfo.h> | 25 | #include <asm/bootinfo.h> |
25 | #include <asm/branch.h> | 26 | #include <asm/branch.h> |
@@ -292,6 +293,16 @@ NORET_TYPE void ATTRIB_NORET die(const char * str, struct pt_regs * regs) | |||
292 | printk("%s[#%d]:\n", str, ++die_counter); | 293 | printk("%s[#%d]:\n", str, ++die_counter); |
293 | show_registers(regs); | 294 | show_registers(regs); |
294 | spin_unlock_irq(&die_lock); | 295 | spin_unlock_irq(&die_lock); |
296 | |||
297 | if (in_interrupt()) | ||
298 | panic("Fatal exception in interrupt"); | ||
299 | |||
300 | if (panic_on_oops) { | ||
301 | printk(KERN_EMERG "Fatal exception: panic in 5 seconds\n"); | ||
302 | ssleep(5); | ||
303 | panic("Fatal exception"); | ||
304 | } | ||
305 | |||
295 | do_exit(SIGSEGV); | 306 | do_exit(SIGSEGV); |
296 | } | 307 | } |
297 | 308 | ||