Only Linux EFI images get the barebox kernel command line as load options. A UKI is a plain EFI application, so root=, bootchooser.active= and the other bootargs never reach its kernel. Pass them to every image with a .linux section too: systemd-stub uses the load options as kernel command line unless UEFI Secure Boot is enabled, which barebox never reports.
Assisted-by: Claude:claude-opus-5-5 Signed-off-by: Johannes Schneider <[email protected]> --- efi/loader/bootm.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/efi/loader/bootm.c b/efi/loader/bootm.c index 18539565fd..8a83865458 100644 --- a/efi/loader/bootm.c +++ b/efi/loader/bootm.c @@ -252,7 +252,7 @@ static int efi_loader_bootm(struct image_data *data) int ret = 0; void *fdt; int flags = 0; - size_t size; + size_t size, section_size; memory_bank_first_find_space(&start, &end); @@ -266,7 +266,10 @@ static int efi_loader_bootm(struct image_data *data) return -EINVAL; } - if (filetype_is_linux_efi_image(data->kernel_type)) { + /* systemd-stub passes the load options on as kernel command line */ + if (filetype_is_linux_efi_image(data->kernel_type) || + efi_pe_find_section((void *)os_res->start, size, ".linux", + §ion_size)) { const char *options; options = linux_bootargs_get(); -- 2.43.0
