lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <5ff84e67-075d-4dfd-94da-0b81262b8e0a@linux.dev>
Date: Tue, 19 Aug 2025 21:58:42 +0800
From: Lance Yang <lance.yang@...ux.dev>
To: Petr Mladek <pmladek@...e.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
 Steven Rostedt <rostedt@...dmis.org>, Jonathan Corbet <corbet@....net>,
 linux-kernel@...r.kernel.org, paulmck@...nel.org, john.ogness@...utronix.de,
 Feng Tang <feng.tang@...ux.alibaba.com>
Subject: Re: [PATCH] panic: Clean up message about deprecated 'panic_print'
 parameter



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@...e.com>

Nice cleanup! This makes the code cleaner and the message
more direct. So, feel free to add:

Reviewed-by: Lance Yang <lance.yang@...ux.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);
>   }
>   


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ