
On Fri, Mar 17, 2023 at 12:29:18PM -0600, Simon Glass wrote:
Hi Tom,
On Fri, 17 Mar 2023 at 08:34, Tom Rini trini@konsulko.com wrote:
On Thu, Mar 16, 2023 at 11:25:17PM -0600, Simon Glass wrote:
Hi Tom,
On Thu, 2 Mar 2023 at 08:14, Tom Rini trini@konsulko.com wrote:
On Wed, Mar 01, 2023 at 08:39:27PM -0700, Simon Glass wrote:
These two features use a lot of common options. Move them into a common CONFIG to reduce duplication.
Resync defconfigs since this makes a lot of changes.
Signed-off-by: Simon Glass sjg@chromium.org
[snip]
diff --git a/boot/Kconfig b/boot/Kconfig index da18d4738a7..7f7ec208a54 100644 --- a/boot/Kconfig +++ b/boot/Kconfig @@ -350,6 +350,35 @@ config PXE_UTILS help Utilities for parsing PXE file formats.
+config BOOT_DEFAULTS
bool # Common defaults for standard boot and distroboot
imply USE_BOOTCOMMAND
# Bring in some defaults which are generally needed. Boards can drop
# these as needed to save code space. Bootstd does not generally require
# the commands themselves to be enabled, but this is how some of the
# functionality is controlled at present
select CMD_ENV_EXISTS
imply CMD_EXT2
imply CMD_EXT4
imply CMD_FAT
imply CMD_FS_GENERIC
imply CMD_PART if PARTITIONS
imply CMD_DHCP if NET
imply CMD_MII if NET
imply CMD_PING if NET
imply CMD_PXE if NET
imply USB_STORAGE
imply SUPPORT_RAW_INITRD
imply ENV_VARS_UBOOT_CONFIG
imply EFI_PARTITION
imply ISO_PARTITION
select CMD_BOOTI if ARM64
select CMD_BOOTZ if ARM && !ARM64
help
These are not required but are commonly needed to support a good
selection of booting methods. Enable this to improve the capability
of U-Boot to boot various images.
We want the more heavy-handed select rather than imply here, as this is part of making sure people do end up with a set of default that will work and not unexpectedly fail to boot off-the-shelf things.
But then boards cannot override it. This is a 'default' option that intends to bring in things that make it easier for the user to get right. But we do need to allow for people to use standard boot in more constrained ways.
These are things that boards aren't supposed to override, which is why they're select'd because the board has chosen to use one of the "give me good defaults" options. So "select" as is done currently is what I want here, for now. We can evaluate later if there's a good reason to not select things.
OK got it, I'll respin this series. This will make it impossible for boards to override things like EXT4,
To reiterate, "impossible for boards to override" is a feature. A very intentional feature. If you're selecting the "boot almost any OS/distro" option, you don't get to then override things like this.
But we could give BOOT_DEFAULTS a name to allow it to be disabled.
We can look at, in the future, some ways to make it possible / easy for things like using standard boot and not having hush, or other customizations for specific use cases. But this is the generic "work for anything" option and workflow we're in right now.