* + panic-add-panic_sys_info=-setup-option-for-kernel-cmdline.patch added to mm-nonmm-unstable branch
@ 2025-07-03 22:41 Andrew Morton
0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2025-07-03 22:41 UTC (permalink / raw)
To: mm-commits, rostedt, pmladek, paulmck, lance.yang, john.ogness,
corbet, feng.tang, akpm
The patch titled
Subject: panic: add 'panic_sys_info=' setup option for kernel cmdline
has been added to the -mm mm-nonmm-unstable branch. Its filename is
panic-add-panic_sys_info=-setup-option-for-kernel-cmdline.patch
This patch will shortly appear at
https://git.kernel.org/pub/scm/linux/kernel/git/akpm/25-new.git/tree/patches/panic-add-panic_sys_info=-setup-option-for-kernel-cmdline.patch
This patch will later appear in the mm-nonmm-unstable branch at
git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
Before you just go and hit "reply", please:
a) Consider who else should be cc'ed
b) Prefer to cc a suitable mailing list as well
c) Ideally: find the original patch on the mailing list and do a
reply-to-all to that, adding suitable additional cc's
*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***
The -mm tree is included into linux-next via the mm-everything
branch at git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
and is updated there every 2-3 working days
------------------------------------------------------
From: Feng Tang <feng.tang@linux.alibaba.com>
Subject: panic: add 'panic_sys_info=' setup option for kernel cmdline
Date: Thu, 3 Jul 2025 10:10:03 +0800
'panic_sys_info=' sysctl interface is already added for runtime setting.
Add counterpart kernel cmdline option for boottime setting.
Link: https://lkml.kernel.org/r/20250703021004.42328-5-feng.tang@linux.alibaba.com
Signed-off-by: Feng Tang <feng.tang@linux.alibaba.com>
Suggested-by: Petr Mladek <pmladek@suse.com>
Cc: John Ogness <john.ogness@linutronix.de>
Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Lance Yang <lance.yang@linux.dev>
Cc: "Paul E . McKenney" <paulmck@kernel.org>
Cc: Steven Rostedt <rostedt@goodmis.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
Documentation/admin-guide/kernel-parameters.txt | 15 ++++++++++++++
kernel/panic.c | 9 ++++++++
2 files changed, 24 insertions(+)
--- a/Documentation/admin-guide/kernel-parameters.txt~panic-add-panic_sys_info=-setup-option-for-kernel-cmdline
+++ a/Documentation/admin-guide/kernel-parameters.txt
@@ -4563,6 +4563,21 @@
Use this option carefully, maybe worth to setup a
bigger log buffer with "log_buf_len" along with this.
+ panic_sys_info= A comma separated list of extra information to be dumped
+ on panic.
+ Format: val[,val...]
+ Where @val can be any of the following:
+
+ tasks: print all tasks info
+ mem: print system memory info
+ timers: print timers info
+ locks: print locks info if CONFIG_LOCKDEP is on
+ ftrace: print ftrace buffer
+ all_bt: print all CPUs backtrace (if available in the arch)
+ blocked_tasks: print only tasks in uninterruptible (blocked) state
+
+ This is a human readable alternative to the 'panic_print' option.
+
parkbd.port= [HW] Parallel port number the keyboard adapter is
connected to, default is 0.
Format: <parport#>
--- a/kernel/panic.c~panic-add-panic_sys_info=-setup-option-for-kernel-cmdline
+++ a/kernel/panic.c
@@ -143,6 +143,15 @@ static __init int kernel_panic_sysctls_i
late_initcall(kernel_panic_sysctls_init);
#endif
+/* The format is "panic_sys_info=tasks,mem,locks,ftrace,..." */
+static int __init setup_panic_sys_info(char *buf)
+{
+ /* There is no risk of race in kernel boot phase */
+ panic_print = sys_info_parse_param(buf);
+ return 1;
+}
+__setup("panic_sys_info=", setup_panic_sys_info);
+
static atomic_t warn_count = ATOMIC_INIT(0);
#ifdef CONFIG_SYSFS
_
Patches currently in -mm which might be from feng.tang@linux.alibaba.com are
panic-clean-up-code-for-console-replay.patch
panic-generalize-panic_prints-function-to-show-sys-info.patch
panic-add-panic_sys_info-sysctl-to-take-human-readable-string-parameter.patch
panic-add-panic_sys_info=-setup-option-for-kernel-cmdline.patch
panic-add-note-that-panic_print-sysctl-interface-is-deprecated.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2025-07-03 22:41 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-03 22:41 + panic-add-panic_sys_info=-setup-option-for-kernel-cmdline.patch added to mm-nonmm-unstable branch Andrew Morton
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.