diff options
| author | Tom Rini <[email protected]> | 2024-07-05 16:36:43 -0600 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2024-07-05 16:36:43 -0600 |
| commit | fd46ea0e701920eb205c2bce9d527bf0dec10b59 (patch) | |
| tree | 7fde587608497f2b1956713e8312c39d98a26b02 /boot | |
| parent | 18908395edcee8450d742c670610557751866393 (diff) | |
| parent | 7d22317a18e3ace2311c741bea74efa72299e57a (diff) | |
Merge branch '2024-07-05-assorted-updates'
- Re-instate the zlib update, so we can fix it for this release,
assorted whitespace cleanups, allow mkimage to 'auto-conf' signing of
scripts, enhance ELF image support, add more HW rev support to e1000
driver, update am64x_evm config, correct mpc8xxx watchdog, update
phycore-am6 docs.
Diffstat (limited to 'boot')
| -rw-r--r-- | boot/Kconfig | 8 | ||||
| -rw-r--r-- | boot/bootm_os.c | 18 | ||||
| -rw-r--r-- | boot/image-fit.c | 3 | ||||
| -rw-r--r-- | boot/image.c | 5 |
4 files changed, 28 insertions, 6 deletions
diff --git a/boot/Kconfig b/boot/Kconfig index 11175fb7bb2..ffcae840a50 100644 --- a/boot/Kconfig +++ b/boot/Kconfig @@ -150,10 +150,10 @@ config FIT_IMAGE_POST_PROCESS processed before being added to the FIT image). config FIT_PRINT - bool "Support FIT printing" - default y - help - Support printing the content of the fitImage in a verbose manner. + bool "Support FIT printing" + default y + help + Support printing the content of the fitImage in a verbose manner. config SPL_FIT bool "Support Flattened Image Tree within SPL" diff --git a/boot/bootm_os.c b/boot/bootm_os.c index 15297ddb530..6a6621706f7 100644 --- a/boot/bootm_os.c +++ b/boot/bootm_os.c @@ -8,6 +8,7 @@ #include <bootstage.h> #include <cpu_func.h> #include <efi_loader.h> +#include <elf.h> #include <env.h> #include <fdt_support.h> #include <image.h> @@ -394,6 +395,20 @@ static int do_bootm_qnxelf(int flag, struct bootm_info *bmi) } #endif +#if defined(CONFIG_BOOTM_ELF) +static int do_bootm_elf(int flag, struct bootm_info *bmi) +{ + Bootelf_flags flags = { .autostart = 1 }; + + if (flag != BOOTM_STATE_OS_GO) + return 0; + + bootelf(bmi->images->ep, flags, 0, NULL); + + return 1; +} +#endif + #ifdef CONFIG_INTEGRITY static int do_bootm_integrity(int flag, struct bootm_info *bmi) { @@ -535,6 +550,9 @@ static boot_os_fn *boot_os[] = { #ifdef CONFIG_BOOTM_EFI [IH_OS_EFI] = do_bootm_efi, #endif +#if defined(CONFIG_BOOTM_ELF) + [IH_OS_ELF] = do_bootm_elf, +#endif }; /* Allow for arch specific config before we boot */ diff --git a/boot/image-fit.c b/boot/image-fit.c index f6464bcf620..9253f81fff5 100644 --- a/boot/image-fit.c +++ b/boot/image-fit.c @@ -2175,7 +2175,8 @@ int fit_image_load(struct bootm_headers *images, ulong addr, fit_image_check_os(fit, noffset, IH_OS_TEE) || fit_image_check_os(fit, noffset, IH_OS_OPENRTOS) || fit_image_check_os(fit, noffset, IH_OS_EFI) || - fit_image_check_os(fit, noffset, IH_OS_VXWORKS); + fit_image_check_os(fit, noffset, IH_OS_VXWORKS) || + fit_image_check_os(fit, noffset, IH_OS_ELF); /* * If either of the checks fail, we should report an error, but diff --git a/boot/image.c b/boot/image.c index fc774d605d1..abac254e026 100644 --- a/boot/image.c +++ b/boot/image.c @@ -130,7 +130,10 @@ static const table_entry_t uimage_os[] = { { IH_OS_OPENRTOS, "openrtos", "OpenRTOS", }, #endif { IH_OS_OPENSBI, "opensbi", "RISC-V OpenSBI", }, - { IH_OS_EFI, "efi", "EFI Firmware" }, + { IH_OS_EFI, "efi", "EFI Firmware" }, +#ifdef CONFIG_BOOTM_ELF + { IH_OS_ELF, "elf", "ELF Image" }, +#endif { -1, "", "", }, }; |
