Re: [tip: x86/boot] x86/boot: Move kernel cmdline setup earlier in the boot process (again)

From: Ingo Molnar
Date: Mon Apr 08 2024 - 14:28:02 EST



* Borislav Petkov <bp@xxxxxxxxx> wrote:

> On Fri, Mar 29, 2024 at 07:51:13AM -0000, tip-bot2 for Julian Stecklina wrote:
> > The following commit has been merged into the x86/boot branch of tip:
> >
> > Commit-ID: 4faa0e5d6d79fc4c6e1943e8b62a65744d8439a0
> > Gitweb: https://git.kernel.org/tip/4faa0e5d6d79fc4c6e1943e8b62a65744d8439a0
> > Author: Julian Stecklina <julian.stecklina@xxxxxxxxxxxxxxxxxxxxx>
> > AuthorDate: Thu, 28 Mar 2024 16:42:12 +01:00
> > Committer: Ingo Molnar <mingo@xxxxxxxxxx>
> > CommitterDate: Fri, 29 Mar 2024 08:19:12 +01:00
> >
> > x86/boot: Move kernel cmdline setup earlier in the boot process (again)
>
> ...
>
> > The order is now:
> >
> > setup_arch():
> > -> Assemble final command line:
> > boot_command_line = builtin_cmdline + boot_cmdline
> >
> > -> early_cpu_init()
> > -> early_identify_cpu()
> > -> sld_setup()
> > -> sld_state_setup()
> > -> Looks for split_lock_detect in boot_command_line
> >
> > -> e820__memory_setup()
> >
> > -> parse_early_param()
>
> So that thing. Should we do something like the silly thing below so that
> it catches potential issues with parsing builtin cmdline stuff too early?

Yep, that's a good idea.

Acked-by: Ingo Molnar <mingo@xxxxxxxxxx>

Ingo