From: Ilias Apalodimas <ilias.apalodimas@linaro.org>
To: Masahisa Kojima <masahisa.kojima@linaro.org>
Cc: u-boot@lists.denx.de, Heinrich Schuchardt <xypron.glpk@gmx.de>,
Simon Glass <sjg@chromium.org>,
Takahiro Akashi <takahiro.akashi@linaro.org>,
Mark Kettenis <mark.kettenis@xs4all.nl>,
Bin Meng <bmeng.cn@gmail.com>
Subject: Re: [RESEND v9 8/9] doc:bootmenu: add description for UEFI boot support
Date: Mon, 18 Jul 2022 16:05:14 +0300 [thread overview]
Message-ID: <CAC_iWj+z1TpAE8_QxAOfa6TUrQk2Sv4U1cBgpyA8D2deXGWL9g@mail.gmail.com> (raw)
In-Reply-To: <20220715144749.30564-9-masahisa.kojima@linaro.org>
Hi Kojima-san
On Fri, 15 Jul 2022 at 17:45, Masahisa Kojima
<masahisa.kojima@linaro.org> wrote:
>
> The bootmenu enumerates the UEFI boot options
> for boot device selection.
> This commit adds the description how the UEFI boot work
> in bootmenu. This commit also adds "Synopsis", "Description"
> and "Configuration" sections to follow the U-Boot command
> documentation format.
>
> Signed-off-by: Masahisa Kojima <masahisa.kojima@linaro.org>
> ---
> No change since v7
>
> Changes in v7:
> - update the description what bootmenu do for uefi-related boot menu
> - add default behavior when user exits from bootmenu
>
> Changes in v6:
> - remove distro boot related contents because the distro boot
> support in bootmenu is dropped
> - update uefi entry example
> - add [delay] argument of bootmenu command
> - add description to enable uefi boot entry
>
> Changes in v5:
> - follow the cmd documentation format same as other command, add "Synopsis",
> "Description" add "Configuration" sections
>
> Newly created in v4
>
> doc/usage/cmd/bootmenu.rst | 74 ++++++++++++++++++++++++++++++++++++++
> 1 file changed, 74 insertions(+)
>
> diff --git a/doc/usage/cmd/bootmenu.rst b/doc/usage/cmd/bootmenu.rst
> index 9430f8c9aa..69435090a2 100644
> --- a/doc/usage/cmd/bootmenu.rst
> +++ b/doc/usage/cmd/bootmenu.rst
> @@ -4,6 +4,15 @@
> bootmenu command
> ================
>
> +Synopsis
> +--------
> +::
> +
> + bootmenu [delay]
> +
> +Description
> +-----------
> +
> The "bootmenu" command uses U-Boot menu interfaces and provides
> a simple mechanism for creating menus with different boot items.
> The cursor keys "Up" and "Down" are used for navigation through
> @@ -79,6 +88,55 @@ The above example will be rendered as below::
> The selected menu entry will be highlighted - it will have inverted
> background and text colors.
>
> +UEFI boot variable enumeration
> +''''''''''''''''''''''''''''''
> +If enabled, the bootmenu command will automatically generate and add
> +UEFI-related boot menu entries for the following items.
> +
> + * possible bootable media with default file names
> + * user-defined UEFI boot options
> +
> +The bootmenu automatically enumerates the possible bootable
> +media devices supporting EFI_SIMPLE_FILE_SYSTEM_PROTOCOL.
> +This auto generated entry is named as "<interface> <devnum>:<part>" format.
> +(e.g. "usb 0:1")
> +
> +The bootmenu displays the UEFI-related menu entries in order of "BootOrder".
> +When the user selects the UEFI boot menu entry, the bootmenu sets
> +the selected boot variable index to "BootNext" without non-volatile attribute,
> +then call the uefi boot manager with the command "bootefi bootmgr".
> +
> +Example bootmenu is as below::
> +
> + *** U-Boot Boot Menu ***
> +
> + mmc 0:1
> + mmc 0:2
> + debian
> + nvme 0:1
> + ubuntu
> + nvme 0:2
> + usb 0:2
> + U-Boot console
> +
> +Default behavior when user exits from the bootmenu
> +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> +User can exit from bootmenu by selecting the last entry
> +"U-Boot console"/"Quit" or ESC/CTRL+C key.
> +
> +When the CONFIG_BOOTMENU_DISABLE_UBOOT_CONSOLE is disabled,
> +user exits from the bootmenu and returns to the U-Boot console.
> +
> +When the CONFIG_BOOTMENU_DISABLE_UBOOT_CONSOLE is enabled, user can not
> +enter the U-Boot console. When the user exits from the bootmenu,
> +the bootmenu invokes the following default behabior.
Behavior
> +
> + * if CONFIG_CMD_BOOTEFI_BOOTMGR is enabled, execute "bootefi bootmgr" command
> + * "bootefi bootmgr" fails or is not enabled, then execute "run bootcmt" command.
"run bootcmd"
> +
> +Configuration
> +-------------
> +
> The "bootmenu" command is enabled by::
>
> CONFIG_CMD_BOOTMENU=y
> @@ -88,3 +146,19 @@ To run the bootmenu at startup add these additional settings::
> CONFIG_AUTOBOOT_KEYED=y
> CONFIG_BOOTDELAY=30
> CONFIG_AUTOBOOT_MENU_SHOW=y
> +
> +UEFI boot variable enumeration is enabled by::
> +
> + CONFIG_CMD_BOOTEFI_BOOTMGR=y
> +
> +To improve the product security, entering U-Boot console from bootmenu
> +can be disabled by::
> +
> + CONFIG_BOOTMENU_DISABLE_UBOOT_CONSOLE=y
> +
> +To scan the discoverable devices connected to the buses such as
> +USB and PCIe prior to bootmenu showing up, CONFIG_PREBOOT can be
> +used to run the command before showing the bootmenu, i.e.::
> +
> + CONFIG_USE_PREBOOT=y
> + CONFIG_PREBOOT="pci enum; usb start; scsi scan; nvme scan; virtio scan"
> --
> 2.17.1
>
With these changes
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
next prev parent reply other threads:[~2022-07-18 13:05 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-15 14:47 [RESEND v9 0/9] enable menu-driven UEFI variable maintenance Masahisa Kojima
2022-07-15 14:47 ` [RESEND v9 1/9] efi_loader: move udevice pointer into struct efi_object Masahisa Kojima
2022-07-17 8:09 ` Heinrich Schuchardt
2022-07-17 11:23 ` Heinrich Schuchardt
2022-07-20 5:23 ` Takahiro Akashi
2022-07-20 7:37 ` Heinrich Schuchardt
2022-07-22 2:00 ` Masahisa Kojima
2022-07-19 23:56 ` Takahiro Akashi
2022-07-20 7:44 ` Heinrich Schuchardt
2022-07-22 2:42 ` Takahiro Akashi
2022-07-15 14:47 ` [RESEND v9 2/9] eficonfig: menu-driven addition of UEFI boot option Masahisa Kojima
2022-07-18 13:31 ` Ilias Apalodimas
2022-07-18 23:06 ` Masahisa Kojima
2022-07-19 7:33 ` Ilias Apalodimas
2022-07-19 10:11 ` Ilias Apalodimas
2022-07-22 2:01 ` Masahisa Kojima
2022-07-15 14:47 ` [RESEND v9 3/9] eficonfig: add "Edit Boot Option" menu entry Masahisa Kojima
2022-07-15 14:47 ` [RESEND v9 4/9] menu: add KEY_PLUS and KEY_MINUS handling Masahisa Kojima
2022-07-18 12:39 ` Ilias Apalodimas
2022-07-15 14:47 ` [RESEND v9 5/9] eficonfig: add "Change Boot Order" menu entry Masahisa Kojima
2022-07-19 13:09 ` Ilias Apalodimas
2022-07-15 14:47 ` [RESEND v9 6/9] eficonfig: add "Delete Boot Option" " Masahisa Kojima
2022-07-15 14:47 ` [RESEND v9 7/9] bootmenu: add removable media entries Masahisa Kojima
2022-07-20 14:07 ` Ilias Apalodimas
2022-07-15 14:47 ` [RESEND v9 8/9] doc:bootmenu: add description for UEFI boot support Masahisa Kojima
2022-07-18 13:05 ` Ilias Apalodimas [this message]
2022-07-15 14:47 ` [RESEND v9 9/9] doc:eficonfig: add documentation for eficonfig command Masahisa Kojima
2022-07-19 8:03 ` Ilias Apalodimas
2022-07-19 10:15 ` Masahisa Kojima
2022-07-19 12:52 ` Ilias Apalodimas
2022-07-22 2:03 ` Masahisa Kojima
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=CAC_iWj+z1TpAE8_QxAOfa6TUrQk2Sv4U1cBgpyA8D2deXGWL9g@mail.gmail.com \
--to=ilias.apalodimas@linaro.org \
--cc=bmeng.cn@gmail.com \
--cc=mark.kettenis@xs4all.nl \
--cc=masahisa.kojima@linaro.org \
--cc=sjg@chromium.org \
--cc=takahiro.akashi@linaro.org \
--cc=u-boot@lists.denx.de \
--cc=xypron.glpk@gmx.de \
/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;
as well as URLs for NNTP newsgroup(s).