From: Lance Yang <lance.yang@linux.dev>
To: Petr Mladek <pmladek@suse.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Steven Rostedt <rostedt@goodmis.org>,
Jonathan Corbet <corbet@lwn.net>,
linux-kernel@vger.kernel.org, paulmck@kernel.org,
john.ogness@linutronix.de,
Feng Tang <feng.tang@linux.alibaba.com>
Subject: Re: [PATCH] panic: Clean up message about deprecated 'panic_print' parameter
Date: Tue, 19 Aug 2025 21:58:42 +0800 [thread overview]
Message-ID: <5ff84e67-075d-4dfd-94da-0b81262b8e0a@linux.dev> (raw)
In-Reply-To: <aKRJKZHgcxyNF3y7@pathway.suse.cz>
On 2025/8/19 17:51, Petr Mladek wrote:
> Remove duplication of the message about the deprecated 'panic_print'
> parameter.
>
> Also make the wording more direct. Make it clear that the new
> parameters already exist and should be used instead.
>
> Signed-off-by: Petr Mladek <pmladek@suse.com>
Nice cleanup! This makes the code cleaner and the message
more direct. So, feel free to add:
Reviewed-by: Lance Yang <lance.yang@linux.dev>
Thanks,
Lance
> ---
> This can be used as a follow up patch.
> Or feel free to squash it into the 3rd patch.
>
> kernel/panic.c | 11 ++++++++---
> 1 file changed, 8 insertions(+), 3 deletions(-)
>
> diff --git a/kernel/panic.c b/kernel/panic.c
> index 12a10e17ab4a..d3907fd95d72 100644
> --- a/kernel/panic.c
> +++ b/kernel/panic.c
> @@ -122,10 +122,15 @@ static int proc_taint(const struct ctl_table *table, int write,
> return err;
> }
>
> +static void panic_print_deprecated(void)
> +{
> + pr_info_once("Kernel: The 'panic_print' parameter is now deprecated. Please use 'panic_sys_info' and 'panic_console_replay' instead.\n");
> +}
> +
> static int sysctl_panic_print_handler(const struct ctl_table *table, int write,
> void *buffer, size_t *lenp, loff_t *ppos)
> {
> - pr_info_once("Kernel: 'panic_print' sysctl interface will be obsoleted by both 'panic_sys_info' and 'panic_console_replay'\n");
> + panic_print_deprecated();
> return proc_doulongvec_minmax(table, write, buffer, lenp, ppos);
> }
>
> @@ -944,13 +949,13 @@ core_param(panic_console_replay, panic_console_replay, bool, 0644);
>
> static int panic_print_set(const char *val, const struct kernel_param *kp)
> {
> - pr_info_once("Kernel: 'panic_print' parameter will be obsoleted by both 'panic_sys_info' and 'panic_console_replay'\n");
> + panic_print_deprecated();
> return param_set_ulong(val, kp);
> }
>
> static int panic_print_get(char *val, const struct kernel_param *kp)
> {
> - pr_info_once("Kernel: 'panic_print' parameter will be obsoleted by both 'panic_sys_info' and 'panic_console_replay'\n");
> + panic_print_deprecated();
> return param_get_ulong(val, kp);
> }
>
next prev parent reply other threads:[~2025-08-19 13:58 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-15 7:14 [PATCH 0/3] follow up patches for panic_print's generalization Feng Tang
2025-08-15 7:14 ` [PATCH 1/3] lib/sys_info: handle sys_info_mask==0 case Feng Tang
2025-08-19 8:34 ` Petr Mladek
2025-08-25 1:05 ` Feng Tang
2025-08-15 7:14 ` [PATCH 2/3] panic: refine the document for 'panic_print' Feng Tang
2025-08-19 8:35 ` Petr Mladek
2025-08-15 7:14 ` [PATCH 3/3] panic: add note that 'panic_print' parameter is deprecated Feng Tang
2025-08-19 9:48 ` Petr Mladek
2025-08-19 9:51 ` [PATCH] panic: Clean up message about deprecated 'panic_print' parameter Petr Mladek
2025-08-19 13:58 ` Lance Yang [this message]
2025-08-20 1:31 ` kernel test robot
2025-08-20 1:54 ` Lance Yang
2025-08-20 1:56 ` Lance Yang
2025-08-20 8:57 ` Lance Yang
2025-08-20 9:33 ` Petr Mladek
2025-08-20 9:40 ` [PATCH v2] " Petr Mladek
2025-08-20 11:03 ` Lance Yang
2025-08-25 1:01 ` Feng Tang
2025-08-20 10:39 ` [PATCH] " Lance Yang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5ff84e67-075d-4dfd-94da-0b81262b8e0a@linux.dev \
--to=lance.yang@linux.dev \
--cc=akpm@linux-foundation.org \
--cc=corbet@lwn.net \
--cc=feng.tang@linux.alibaba.com \
--cc=john.ogness@linutronix.de \
--cc=linux-kernel@vger.kernel.org \
--cc=paulmck@kernel.org \
--cc=pmladek@suse.com \
--cc=rostedt@goodmis.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.