[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <8de1aca1-81bf-4c4b-b5b7-16f76640fdb1@paulmck-laptop>
Date: Fri, 4 Aug 2023 10:33:28 -0700
From: "Paul E. McKenney" <paulmck@...nel.org>
To: Alexey Dobriyan <adobriyan@...il.com>
Cc: akpm@...ux-foundation.org, mhiramat@...nel.org, arnd@...nel.org,
ndesaulniers@...gle.com, sfr@...b.auug.org.au,
linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
kernel-team@...a.com
Subject: Re: [PATCH RFC bootconfig] 2/2] fs/proc: Add /proc/cmdline_image for
embedded arguments
On Fri, Aug 04, 2023 at 08:28:08PM +0300, Alexey Dobriyan wrote:
> On Thu, Jul 27, 2023 at 08:37:01PM -0700, Paul E. McKenney wrote:
> > In kernels built with CONFIG_BOOT_CONFIG_FORCE=y, /proc/cmdline will show
> > all kernel boot parameters, both those supplied by the boot loader and
> > those embedded in the kernel image. This works well for those who just
> > want to see all of the kernel boot parameters, but is not helpful to those
> > who need to see only those parameters that were embedded into the kernel
> > image. This is especially important in situations where there are many
> > kernel images for different kernel versions and kernel configurations,
> > all of which opens the door to a great deal of human error.
> >
> > Therefore, provide a /proc/cmdline_image file that shows only those kernel
> > boot parameters that were embedded in the kernel image. The output
> > is in boot-image format, which allows easy reconcilation against the
> > boot-config source file.
> >
> > Why put this in /proc? Because it is quite similar to /proc/cmdline, so
> > it makes sense to put it in the same place that /proc/cmdline is located.
> >
> > Signed-off-by: Paul E. McKenney <paulmck@...nel.org>
> > Cc: Andrew Morton <akpm@...ux-foundation.org>
> > Cc: Alexey Dobriyan <adobriyan@...il.com>
> > Cc: Masami Hiramatsu <mhiramat@...nel.org>
> > Cc: <linux-fsdevel@...r.kernel.org>
> >
> > Signed-off-by: Paul E. McKenney <paulmck@...nel.org>
> > ---
> > fs/proc/cmdline.c | 12 ++++++++++++
> > include/linux/init.h | 11 ++++++-----
> > init/main.c | 9 +++++++++
>
> Same thing,
>
> Please if possible put /proc/x into fs/proc/x.c so that it is easier to
> find source. Not all /proc follows this convention but still.
>
> I don't like this name too (but less than the other one).
> Is it Boot Image Format (BIF). If yes, maybe add it as /proc/cmdline.bif ?
>
> I don't know what's the good name.
It turns out that the already existing /proc/bootconfig makes this
new /proc/bootconfig_image unnecessary, so I have dropped this patch.
Imagine my embarrassment upon learning that /proc/bootconfig has been
around since v5.5! ;-)
Thanx, Paul
Powered by blists - more mailing lists