Linux Trace Kernel
 help / color / mirror / Atom feed
From: Masami Hiramatsu (Google) <mhiramat@kernel.org>
To: Breno Leitao <leitao@debian.org>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	Nathan Chancellor <nathan@kernel.org>,
	paulmck@kernel.org, Nicolas Schier <nsc@kernel.org>,
	Thomas Gleixner <tglx@kernel.org>, Ingo Molnar <mingo@redhat.com>,
	Borislav Petkov <bp@alien8.de>,
	Dave Hansen <dave.hansen@linux.intel.com>,
	x86@kernel.org, "H. Peter Anvin" <hpa@zytor.com>,
	linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org,
	linux-kbuild@vger.kernel.org, bpf@vger.kernel.org,
	kernel-team@meta.com
Subject: Re: [PATCH v4 6/7] Documentation: bootconfig: document build-time cmdline rendering
Date: Wed, 10 Jun 2026 23:37:20 +0900	[thread overview]
Message-ID: <20260610233720.82fe59cf42aa57659c2e5697@kernel.org> (raw)
In-Reply-To: <20260609-bootconfig_using_tools-v4-6-73c463f03a97@debian.org>

On Tue, 09 Jun 2026 03:28:33 -0700
Breno Leitao <leitao@debian.org> wrote:

> Add a section describing CONFIG_BOOT_CONFIG_EMBED_CMDLINE: what it
> does (renders the embedded "kernel" subtree to a flat cmdline at
> build time so early_param() handlers see the values), what it
> requires (BOOT_CONFIG_EMBED, a non-empty BOOT_CONFIG_EMBED_FILE,
> and ARCH_SUPPORTS_CMDLINE_FROM_BOOTCONFIG -- currently x86 only),
> the bootconfig opt-in semantics, the initrd-vs-embedded precedence,
> and the soft-error overflow behavior.

Hi Breno,

Thanks for adding the document. But related to the Sashiko's comment,
I believe it's necessary to pre-describe in this document how the
kernel behaves with various combinations of cmdline and bootconfig,
both embbedded and initrd/bootloader.

We can have these ways to pass the kernel options.

- bootloader cmdline
- embedded cmdline
- initrd bootconfig
- embedded bootconfig (standard/cmdline)

Clearly, we will have the option to choose between a standard embedded
boot configuration or a command-line one, not either, but the behavior
is different. I confirmed that is covered.

Embedded bootconfig is a kind of default bootconfig, which is NOT used
when initrd has another bootconfig. I made this design because of
/proc/bootconfig, which is not merged with embedded one. However, 
CONFIG_BOOT_CONFIG_EMBED_CMDLINE will be a bit different, if it is
embedded and "bootconfig" feature is enabled, the embbedded one
has been used already. 

To avoid confusion, when this option is used, shouldn't we treat it
the same way as if embedded command lines were enabled, and either
not display it in /proc/bootconfig (or always display it, by merging
the rendered string)?

Thank you,


-- 
Masami Hiramatsu (Google) <mhiramat@kernel.org>

  reply	other threads:[~2026-06-10 14:37 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-09 10:28 [PATCH v4 0/7] bootconfig: embed kernel.* cmdline at build time Breno Leitao
2026-06-09 10:28 ` [PATCH v4 1/7] bootconfig: fix NULL-pointer arithmetic in xbc_snprint_cmdline() Breno Leitao
2026-06-09 10:28 ` [PATCH v4 2/7] bootconfig: render descendant keys when xbc_snprint_cmdline() root has a value Breno Leitao
2026-06-09 10:28 ` [PATCH v4 3/7] bootconfig: render embedded bootconfig as a kernel cmdline at build time Breno Leitao
2026-06-10 13:44   ` Julian Braha
2026-06-10 14:50     ` Breno Leitao
2026-06-09 10:28 ` [PATCH v4 4/7] bootconfig: clean build-time tools/bootconfig from make clean Breno Leitao
2026-06-09 10:28 ` [PATCH v4 5/7] bootconfig: add xbc_prepend_embedded_cmdline() helper Breno Leitao
2026-06-09 10:28 ` [PATCH v4 6/7] Documentation: bootconfig: document build-time cmdline rendering Breno Leitao
2026-06-10 14:37   ` Masami Hiramatsu [this message]
2026-06-10 14:58     ` Breno Leitao
2026-06-09 10:28 ` [PATCH v4 7/7] x86/setup: prepend embedded bootconfig cmdline before parse_early_param Breno Leitao

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=20260610233720.82fe59cf42aa57659c2e5697@kernel.org \
    --to=mhiramat@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=bp@alien8.de \
    --cc=bpf@vger.kernel.org \
    --cc=dave.hansen@linux.intel.com \
    --cc=hpa@zytor.com \
    --cc=kernel-team@meta.com \
    --cc=leitao@debian.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-trace-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=nathan@kernel.org \
    --cc=nsc@kernel.org \
    --cc=paulmck@kernel.org \
    --cc=tglx@kernel.org \
    --cc=x86@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox