diff options
| author | Tom Rini <[email protected]> | 2025-06-28 08:10:43 -0600 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2025-06-28 08:10:43 -0600 |
| commit | 7027b445cc0bfb86204ecb1f1fe596f5895048d9 (patch) | |
| tree | f27d6f3425dea4bc984c6fede0e7ce73f5d17917 | |
| parent | 359e3012921f2fc2d43f3c4e320a752173f82b82 (diff) | |
| parent | e80baf06af50a4c8c6f41e9b67f9931f964ced87 (diff) | |
Merge tag 'efi-2025-07-rc6' of https://source.denx.de/u-boot/custodians/u-boot-efi
Pull request efi-2025-07-rc6
Documentation:
* Describe usage of U-Boot environment variables in extlinux.conf
UEFI:
* Add missing variable initialization in
efi_bootmgr_update_media_device_boot_option
| -rw-r--r-- | doc/README.pxe | 3 | ||||
| -rw-r--r-- | doc/develop/distro.rst | 7 | ||||
| -rw-r--r-- | lib/efi_loader/efi_bootmgr.c | 2 |
3 files changed, 10 insertions, 2 deletions
diff --git a/doc/README.pxe b/doc/README.pxe index 9fff2cd5ae9..ba189080e8c 100644 --- a/doc/README.pxe +++ b/doc/README.pxe @@ -178,7 +178,8 @@ devicetree-overlay <path> [...] - if this label is chosen, use tftp to retrieve kaslrseed - set this label to request random number from hwrng as kaslr seed. append <string> - use <string> as the kernel command line when booting this - label. + label. Environment variable references like ${var} are + substituted before boot. initrd <path> - if this label is chosen, use tftp to retrieve the initrd at <path>. it will be stored at the address indicated in diff --git a/doc/develop/distro.rst b/doc/develop/distro.rst index 1d2f9c4c32b..01efce40a29 100644 --- a/doc/develop/distro.rst +++ b/doc/develop/distro.rst @@ -92,6 +92,13 @@ That said, we have some differences to these documents, namely: * If ``-`` is passed as fdt argument and ``CONFIG_SUPPORT_PASSING_ATAGS`` is enabled, then no device tree will be used (legacy booting / pre-dtb kernel). +* The ``append`` string may use environment variables. For example, an + A/B boot setup could use ``append root=PARTLABEL=root_${bootslot}`` + to set the root filesystem to the right one for the selected slot, + assuming the ``bootslot`` environment variable is set before the + extlinux.conf file is processed, and the partition is labeled to + match. + See also doc/README.pxe under 'pxe file format'. One example extlinux.conf generated by the Fedora installer is:: diff --git a/lib/efi_loader/efi_bootmgr.c b/lib/efi_loader/efi_bootmgr.c index 1a3461f5a9d..83f4a3525bd 100644 --- a/lib/efi_loader/efi_bootmgr.c +++ b/lib/efi_loader/efi_bootmgr.c @@ -1133,7 +1133,7 @@ efi_status_t efi_bootmgr_update_media_device_boot_option(void) { u32 i; efi_status_t ret; - efi_uintn_t count, num, total; + efi_uintn_t count, num, total = 0; efi_handle_t *handles = NULL; struct eficonfig_media_boot_option *opt = NULL; |
