boot/uboot: add support for building the TI K3 DM into U-Boot

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@ti.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
MyCruft^2
Andreas Dannenberg 2023-06-15 19:23:52 -05:00 committed by Thomas Petazzoni
parent 6134872d28
commit 52ce606c05
2 changed files with 25 additions and 0 deletions

View File

@ -240,6 +240,25 @@ 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)"
# We use the SoC selection defined for the ti-k3-image-gen
# package
depends on BR2_TARGET_TI_K3_IMAGE_GEN
depends on BR2_TARGET_TI_K3_IMAGE_GEN_SOC_AM62AX || BR2_TARGET_TI_K3_IMAGE_GEN_SOC_AM62X
help
Some TI K3 devices need the Device Manager (DM) firmware to
be available for the U-Boot build.
if BR2_TARGET_UBOOT_NEEDS_TI_K3_DM
config BR2_TARGET_UBOOT_TI_K3_DM_SOCNAME
string
default "am62axx" if BR2_TARGET_TI_K3_IMAGE_GEN_SOC_AM62AX
default "am62xx" if BR2_TARGET_TI_K3_IMAGE_GEN_SOC_AM62X
endif
config BR2_TARGET_UBOOT_NEEDS_OPENSBI
bool "U-Boot needs OpenSBI"
depends on BR2_TARGET_OPENSBI

View File

@ -186,6 +186,12 @@ UBOOT_DEPENDENCIES += optee-os
UBOOT_MAKE_OPTS += TEE=$(BINARIES_DIR)/tee.elf
endif
ifeq ($(BR2_TARGET_UBOOT_NEEDS_TI_K3_DM),y)
UBOOT_TI_K3_DM_SOCNAME = $(call qstrip,$(BR2_TARGET_UBOOT_TI_K3_DM_SOCNAME))
UBOOT_DEPENDENCIES += ti-k3-boot-firmware
UBOOT_MAKE_OPTS += DM=$(BINARIES_DIR)/ti-dm/$(UBOOT_TI_K3_DM_SOCNAME)/ipc_echo_testb_mcu1_0_release_strip.xer5f
endif
ifeq ($(BR2_TARGET_UBOOT_NEEDS_OPENSBI),y)
UBOOT_DEPENDENCIES += opensbi
UBOOT_MAKE_OPTS += OPENSBI=$(BINARIES_DIR)/fw_dynamic.bin