[Buildroot] [PATCH v9 03/11] boot/uboot: add support for building the TI K3 DM into U-Boot
Andreas Dannenberg
dannenberg at ti.com
Thu Jun 22 16:02:04 UTC 2023
Certain TI K3 devices such as AM62x and AM62Ax require a Device Manager
(DM) firmnware to be made available to the U-Boot build, which will get
packaged into the "tispl.bin" image tree blob during A53 SPL build.
Without that DM firmware U-Boot will not be functional. To support this,
add a config option called BR2_TARGET_UBOOT_NEEDS_TI_K3_DM to enable
this feature, and another option BR2_TARGET_UBOOT_TI_K3_DM_SOC to allow
setting the name of the SOC which needs to match the corresponding
folder name in the ti-linux-firmware Git repository.
Signed-off-by: Andreas Dannenberg <dannenberg at ti.com>
---
boot/uboot/Config.in | 17 +++++++++++++++++
boot/uboot/uboot.mk | 16 ++++++++++++++++
2 files changed, 33 insertions(+)
diff --git a/boot/uboot/Config.in b/boot/uboot/Config.in
index 085397d03d..7e1dd44196 100644
--- a/boot/uboot/Config.in
+++ b/boot/uboot/Config.in
@@ -240,6 +240,23 @@ config BR2_TARGET_UBOOT_NEEDS_OPTEE_TEE
U-Boot, and that the TEE variable pointing to OPTEE's
tee.elf, is passed during the Buildroot build.
+config BR2_TARGET_UBOOT_NEEDS_TI_K3_DM
+ bool "U-Boot needs TI K3 Device Manager (DM)"
+ help
+ Some TI K3 devices need the Device Manager (DM) firmware
+ to be available for the U-Boot build. Currently supports FW
+ from Git tag 08.06.00.006 by default.
+
+ https://git.ti.com/cgit/processor-firmware/ti-linux-firmware/tree/ti-dm?h=ti-linux-firmware
+
+config BR2_TARGET_UBOOT_TI_K3_DM_SOC
+ string "TI K3 Device Manager (DM) SOC Type"
+ depends on BR2_TARGET_UBOOT_NEEDS_TI_K3_DM
+ help
+ Name of the TI K3 Device Manager (DM) SOC. This needs to
+ match one of the SOC-specific folders in within the ti-dm
+ folder of the ti-linux-firmware Git repository.
+
config BR2_TARGET_UBOOT_NEEDS_OPENSBI
bool "U-Boot needs OpenSBI"
depends on BR2_TARGET_OPENSBI
diff --git a/boot/uboot/uboot.mk b/boot/uboot/uboot.mk
index 4eae8e95c3..48af69bd26 100644
--- a/boot/uboot/uboot.mk
+++ b/boot/uboot/uboot.mk
@@ -184,6 +184,22 @@ UBOOT_DEPENDENCIES += optee-os
UBOOT_MAKE_OPTS += TEE=$(BINARIES_DIR)/tee.elf
endif
+ifeq ($(BR2_TARGET_UBOOT_NEEDS_TI_K3_DM),y)
+# Currently supports the FW from Git tag 08.06.00.006 by default
+TI_K3_DM_VERSION = 340194800a581baf976360386dfc7b5acab8d948
+TI_K3_DM_SITE = https://git.ti.com/processor-firmware/ti-linux-firmware/blobs/raw/$(TI_K3_DM_VERSION)/ti-dm/$(BR2_TARGET_UBOOT_TI_K3_DM_SOC)
+TI_K3_DM_SOURCE = ipc_echo_testb_mcu1_0_release_strip.xer5f
+# This is not really nice but disable the hash check for the DM FW file. Main
+# reason is all those DM FW files for different SoCs have the same(!) name in
+# the Git repository they reside in, so it would be more difficult to distinguish
+# between them for hash checking purposes. To work around this let's just
+# rely and trust the official Git repo at ti.com is known-good which is also
+# accessed through a secure transport.
+BR_NO_CHECK_HASH_FOR += $(TI_K3_DM_SOURCE)
+UBOOT_EXTRA_DOWNLOADS = $(TI_K3_DM_SITE)/$(TI_K3_DM_SOURCE)
+UBOOT_MAKE_OPTS += DM=$(UBOOT_DL_DIR)/$(TI_K3_DM_SOURCE)
+endif
+
ifeq ($(BR2_TARGET_UBOOT_NEEDS_OPENSBI),y)
UBOOT_DEPENDENCIES += opensbi
UBOOT_MAKE_OPTS += OPENSBI=$(BINARIES_DIR)/fw_dynamic.bin
--
2.34.1
More information about the buildroot
mailing list