Skip to content

Commit

Permalink
move x86 specific oops=panic to generic code
Browse files Browse the repository at this point in the history
The oops=panic cmdline option is not x86 specific, move it to generic code.
Update documentation.

Signed-off-by: Olaf Hering <olaf@aepfle.de>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Olaf Hering authored and Linus Torvalds committed Mar 23, 2011
1 parent b259514 commit d404ab0
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 15 deletions.
5 changes: 5 additions & 0 deletions Documentation/kernel-parameters.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1825,6 +1825,11 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
perfmon on Intel CPUs instead of the
CPU specific event set.

oops=panic Always panic on oopses. Default is to just kill the process,
but there is a small probability of deadlocking the machine.
This will also cause panics on machine check exceptions.
Useful together with panic=30 to trigger a reboot.

OSS [HW,OSS]
See Documentation/sound/oss/oss-parameters.txt

Expand Down
5 changes: 0 additions & 5 deletions Documentation/x86/x86_64/boot-options.txt
Original file line number Diff line number Diff line change
Expand Up @@ -293,11 +293,6 @@ IOMMU (input/output memory management unit)

Debugging

oops=panic Always panic on oopses. Default is to just kill the process,
but there is a small probability of deadlocking the machine.
This will also cause panics on machine check exceptions.
Useful together with panic=30 to trigger a reboot.

kstack=N Print N words from the kernel stack in oops dumps.

pagefaulttrace Dump all page faults. Only useful for extreme debugging
Expand Down
10 changes: 0 additions & 10 deletions arch/x86/kernel/dumpstack.c
Original file line number Diff line number Diff line change
Expand Up @@ -322,16 +322,6 @@ void die(const char *str, struct pt_regs *regs, long err)
oops_end(flags, regs, sig);
}

static int __init oops_setup(char *s)
{
if (!s)
return -EINVAL;
if (!strcmp(s, "panic"))
panic_on_oops = 1;
return 0;
}
early_param("oops", oops_setup);

static int __init kstack_setup(char *s)
{
if (!s)
Expand Down
10 changes: 10 additions & 0 deletions kernel/panic.c
Original file line number Diff line number Diff line change
Expand Up @@ -433,3 +433,13 @@ EXPORT_SYMBOL(__stack_chk_fail);

core_param(panic, panic_timeout, int, 0644);
core_param(pause_on_oops, pause_on_oops, int, 0644);

static int __init oops_setup(char *s)
{
if (!s)
return -EINVAL;
if (!strcmp(s, "panic"))
panic_on_oops = 1;
return 0;
}
early_param("oops", oops_setup);

0 comments on commit d404ab0

Please sign in to comment.