Misc fixes for SPL_FIT_SIGNATURE builds
cover Misc fixes for SPL_FIT_SIGNATURE builds
This patch series contains a few fixes for issues found when experimenting with the SPL_FIT_SIGNATURE builds. Some of them are apparently necessary to properly integrate this U-boot feature with build systems such as Yocto, and by extension OpenBMC.
-Klaus
Klaus Heinrich Kiwi (3):
Kconfig: SPL_FIT_SIGNATURE selects FIT_SIGNATURE
Kconfig: SPL_FIT_SIGNATURE requires SPL_LOAD_FIT
Makefile: Add (default) DEVICE_TREE to SPL FIT
Makefile | 1 + common/Kconfig.boot | 2 ++ 2 files changed, 3 insertions(+)
Signature · 1 line
2.25.1
PATCH 1/3 Kconfig: SPL_FIT_SIGNATURE selects FIT_SIGNATURE
Selecting SPL_FIT_SIGNATURE (without selecting U-boot proper verified boot first) breaks the build due to CONFIG_FIT_SIGNATURE_MAX_SIZE being undefined, in addition to Kconfig warnings on RSA and IMAGE_SIGN_INFO unmet dependencies.
---
common/Kconfig.boot | 1 + 1 file changed, 1 insertion(+)
common/Kconfig.boot +1 -0
@@ -162,6 +162,7 @@ config SPL_FIT_PRINT config SPL_FIT_SIGNATURE bool "Enable signature verification of FIT firmware within SPL" depends on SPL_DM + select FIT_SIGNATURE select SPL_FIT select SPL_CRYPTO_SUPPORT select SPL_HASH_SUPPORT
Signature · 1 line
2.25.1
PATCH 2/3 Kconfig: SPL_FIT_SIGNATURE requires SPL_LOAD_FIT
In reply to Klaus Heinrich KiwiHaving the ability to support firmware FIT signatures on the SPL sounds not so useful if the SPL is not supporting to load a (U-boot) firmware as a FIT image.
---
common/Kconfig.boot | 1 + 1 file changed, 1 insertion(+)
common/Kconfig.boot +1 -0
@@ -162,6 +162,7 @@ config SPL_FIT_PRINT config SPL_FIT_SIGNATURE bool "Enable signature verification of FIT firmware within SPL" depends on SPL_DM + depends on SPL_LOAD_FIT || SPL_LOAD_FIT_FULL select FIT_SIGNATURE select SPL_FIT select SPL_CRYPTO_SUPPORT
Signature · 1 line
2.25.1
PATCH 3/3 Makefile: Add (default) DEVICE_TREE to SPL FIT
In reply to Klaus Heinrich KiwiU-boot allows the default device tree to be overridden from the build environment using the DEVICE_TREE variable.
Make sure that we include it in the SPL FIT mkimage build step.
This also fixes a broken image in case CONFIG_OF_LIST and CONFIG_OF_OVERLAY_LIST are unset (i.e., expected to be supplied by the DEVICE_TREE env var).
---
Makefile | 1 + 1 file changed, 1 insertion(+)
Makefile +1 -0
@@ -1386,6 +1386,7 @@ MKIMAGEFLAGS_u-boot.img = -f auto -A $(ARCH) -T firmware -C none -O u-boot \ -a $(CONFIG_SYS_TEXT_BASE) -e $(CONFIG_SYS_UBOOT_START) \ -p $(CONFIG_FIT_EXTERNAL_OFFSET) \ -n "U-Boot $(UBOOTRELEASE) for $(BOARD) board" -E \ + $(patsubst %,-b arch/$(ARCH)/dts/%.dtb,$(subst ",,$(DEVICE_TREE))) \ $(patsubst %,-b arch/$(ARCH)/dts/%.dtb,$(subst ",,$(CONFIG_OF_LIST))) \ $(patsubst %,-b arch/$(ARCH)/dts/%.dtbo,$(subst ",,$(CONFIG_OF_OVERLAY_LIST))) else
Signature · 1 line
2.25.1
PATCH 1/3 Kconfig: SPL_FIT_SIGNATURE selects FIT_SIGNATURE
In reply to Klaus Heinrich KiwiQuoted 6 lines · Klaus Heinrich Kiwi
Selecting
SPL_FIT_SIGNATURE(without selecting U-boot proper verified boot first) breaks the build due toCONFIG_FIT_SIGNATURE_MAX_SIZEbeing undefined, in addition toKconfigwarnings on RSA andIMAGE_SIGN_INFOunmet dependencies.Signed-off-by Klaus Heinrich Kiwi <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 659 bytes Desc: not available URL: <https://lists.denx.de/pipermail/u-boot/attachments/20210225/6bf68846/attachment.sig>
PATCH 2/3 Kconfig: SPL_FIT_SIGNATURE requires SPL_LOAD_FIT
In reply to Klaus Heinrich KiwiQuoted 5 lines · Klaus Heinrich Kiwi
Having the ability to support firmware FIT signatures on the SPL sounds not so useful if the SPL is not supporting to load a (U-boot) firmware as a FIT image.
Signed-off-by Klaus Heinrich Kiwi <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 659 bytes Desc: not available URL: <https://lists.denx.de/pipermail/u-boot/attachments/20210225/98d743f8/attachment.sig>
PATCH 3/3 Makefile: Add (default) DEVICE_TREE to SPL FIT
In reply to Klaus Heinrich KiwiQuoted 10 lines · Klaus Heinrich Kiwi
U-boot allows the default device tree to be overridden from the build environment using the
DEVICE_TREEvariable.Make sure that we include it in the SPL FIT mkimage build step.
This also fixes a broken image in case
CONFIG_OF_LISTandCONFIG_OF_OVERLAY_LISTare unset (i.e., expected to be supplied by theDEVICE_TREEenv var).Signed-off-by Klaus Heinrich Kiwi <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 659 bytes Desc: not available URL: <https://lists.denx.de/pipermail/u-boot/attachments/20210225/44360505/attachment.sig>