[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <59d88de7-369a-44e8-a965-109c8690869e@linux.ibm.com>
Date: Fri, 12 Jul 2024 10:00:09 +0530
From: Sourabh Jain <sourabhjain@...ux.ibm.com>
To: Petr Tesarik <petr.tesarik@...e.com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
"Rafael J. Wysocki" <rafael@...nel.org>,
Eric Biederman <ebiederm@...ssion.com>, kexec@...ts.infradead.org
Cc: linux-kernel@...r.kernel.org, Petr Tesarik <petr@...arici.cz>,
Petr Tesarik <ptesarik@...e.com>
Subject: Re: [PATCH] sysfs/cpu: Make crash_hotplug attribute world-readable
Hello Petr,
Just want to mentioned few points about the commit message. No strong
opinion on changing the commit message.
On 11/07/24 16:04, Petr Tesarik wrote:
> From: Petr Tesarik <ptesarik@...e.com>
>
> There is no reason to restrict access to this attribute, as it merely
> reports whether crash elfcorehdr is automatically updated on CPU hot
> plug/unplug and/or online/offline events.
Now, it is not just elfcorehdr; there could be multiple kexec segments
based on the architecture's needs.
For example, on PowerPC, it is elfcorehdr and FDT.
>
> Note that since commit 79365026f8694 ("crash: add a new kexec flag for
> hotplug support"), this maps to the same flag which is world-accessible
> through /sys/devices/system/memory/crash_hotplug.
The previous comment is more relevant for the kexec_load system call.
For the kexec_file_load system call, the kexec flag introduced in the
commit message
mentioned above is irrelevant. Building kernel with CONFIG_CRASH_HOTPLUG
is enough.
> Signedoff-by: Petr Tesarik <ptesarik@...e.com>
> ---
> drivers/base/cpu.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/base/cpu.c b/drivers/base/cpu.c
> index c61ecb0c2ae2..73d69791d0d3 100644
> --- a/drivers/base/cpu.c
> +++ b/drivers/base/cpu.c
> @@ -308,7 +308,7 @@ static ssize_t crash_hotplug_show(struct device *dev,
> {
> return sysfs_emit(buf, "%d\n", crash_check_hotplug_support());
> }
> -static DEVICE_ATTR_ADMIN_RO(crash_hotplug);
> +static DEVICE_ATTR_RO(crash_hotplug);
I agree, it doesn't have to be readable by admin only.
Acked-by: Sourabh Jain <sourabhjain@...ux.ibm.com>
Thanks for the patch.
- Sourabh
Powered by blists - more mailing lists