]> Git Repo - linux.git/commit
panic: add option to dump all CPUs backtraces in panic_print
authorGuilherme G. Piccoli <[email protected]>
Wed, 23 Mar 2022 23:07:06 +0000 (16:07 -0700)
committerLinus Torvalds <[email protected]>
Thu, 24 Mar 2022 02:00:35 +0000 (19:00 -0700)
commit8d470a45d1a65e6a308aeee5da7f5b37d3303c04
tree868c5db3a56bc8636621215a20ac3b310cb0f611
parenta1ff1de00db21ecb956213f046b79741b64c6b65
panic: add option to dump all CPUs backtraces in panic_print

Currently the "panic_print" parameter/sysctl allows some interesting debug
information to be printed during a panic event.  This is useful for
example in cases the user cannot kdump due to resource limits, or if the
user collects panic logs in a serial output (or pstore) and prefers a fast
reboot instead of a kdump.

Happens that currently there's no way to see all CPUs backtraces in a
panic using "panic_print" on architectures that support that.  We do have
"oops_all_cpu_backtrace" sysctl, but although partially overlapping in the
functionality, they are orthogonal in nature: "panic_print" is a panic
tuning (and we have panics without oopses, like direct calls to panic() or
maybe other paths that don't go through oops_enter() function), and the
original purpose of "oops_all_cpu_backtrace" is to provide more
information on oopses for cases in which the users desire to continue
running the kernel even after an oops, i.e., used in non-panic scenarios.

So, we hereby introduce an additional bit for "panic_print" to allow
dumping the CPUs backtraces during a panic event.

Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Guilherme G. Piccoli <[email protected]>
Reviewed-by: Feng Tang <[email protected]>
Cc: Iurii Zaikin <[email protected]>
Cc: Kees Cook <[email protected]>
Cc: Luis Chamberlain <[email protected]>
Cc: Samuel Iglesias Gonsalvez <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Documentation/admin-guide/kernel-parameters.txt
Documentation/admin-guide/sysctl/kernel.rst
kernel/panic.c
This page took 0.060737 seconds and 4 git commands to generate.