Commit b05de01a authored by Horms's avatar Horms Committed by Tony Luck

[IA64] support panic_on_oops sysctl

Trivial port of this feature from i386
As it stands, panic_on_oops but does nothing on ia64
Signed-Off-By: default avatarHorms <horms@verge.net.au>
Signed-off-by: default avatarTony Luck <tony.luck@intel.com>
parent defbb2c9
...@@ -16,6 +16,7 @@ ...@@ -16,6 +16,7 @@
#include <linux/module.h> /* for EXPORT_SYMBOL */ #include <linux/module.h> /* for EXPORT_SYMBOL */
#include <linux/hardirq.h> #include <linux/hardirq.h>
#include <linux/kprobes.h> #include <linux/kprobes.h>
#include <linux/delay.h> /* for ssleep() */
#include <asm/fpswa.h> #include <asm/fpswa.h>
#include <asm/ia32.h> #include <asm/ia32.h>
...@@ -116,6 +117,13 @@ die (const char *str, struct pt_regs *regs, long err) ...@@ -116,6 +117,13 @@ die (const char *str, struct pt_regs *regs, long err)
bust_spinlocks(0); bust_spinlocks(0);
die.lock_owner = -1; die.lock_owner = -1;
spin_unlock_irq(&die.lock); spin_unlock_irq(&die.lock);
if (panic_on_oops) {
printk(KERN_EMERG "Fatal exception: panic in 5 seconds\n");
ssleep(5);
panic("Fatal exception");
}
do_exit(SIGSEGV); do_exit(SIGSEGV);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment