From eb73b3fc20f152a25b9a804102c3003a76d55b08 Mon Sep 17 00:00:00 2001 From: Max Krummenacher Date: Fri, 7 Jul 2023 13:30:20 +0200 Subject: u-boot-distro-boot: make use of the machine.conf provided var With the kernel moving 32 bit device trees in subdirectories starting with kernel 6.5 the toradex machine configuration files provide the variable KERNEL_DTB_PREFIX. The fit image configuration name is constructed from KERNEL_DTB_PREFIX plus the dtb file name. Make use of the KERNEL_DTB_PREFIX variable to construct the configuration used for booting. As we now also set KERNEL_DTB_PREFIX for the 64 bit machines the inline python works for all machines, thus drop the DTB_PREFIX overrides. Related-to: ELB-5262 Signed-off-by: Max Krummenacher --- recipes-bsp/u-boot/u-boot-distro-boot.bb | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'recipes-bsp') diff --git a/recipes-bsp/u-boot/u-boot-distro-boot.bb b/recipes-bsp/u-boot/u-boot-distro-boot.bb index 61bfa03..4aa80fa 100644 --- a/recipes-bsp/u-boot/u-boot-distro-boot.bb +++ b/recipes-bsp/u-boot/u-boot-distro-boot.bb @@ -12,14 +12,12 @@ SRC_URI = " \ KERNEL_BOOTCMD ??= "bootz" KERNEL_BOOTCMD:aarch64 ?= "booti" -KERNEL_DTB_PREFIX ??= "" -KERNEL_DTB_PREFIX:mx8-generic-bsp ?= "freescale_" -KERNEL_DTB_PREFIX:k3 ?= "ti_" +DTB_PREFIX ??= "${@d.getVar('KERNEL_DTB_PREFIX').replace("/", "_") if d.getVar('KERNEL_DTB_PREFIX') else ''}" inherit deploy do_deploy() { - sed -e 's/@@KERNEL_BOOTCMD@@/${KERNEL_BOOTCMD}/;s/@@KERNEL_IMAGETYPE@@/${KERNEL_IMAGETYPE}/;s/@@KERNEL_DTB_PREFIX@@/${KERNEL_DTB_PREFIX}/' \ + sed -e 's/@@KERNEL_BOOTCMD@@/${KERNEL_BOOTCMD}/;s/@@KERNEL_IMAGETYPE@@/${KERNEL_IMAGETYPE}/;s/@@KERNEL_DTB_PREFIX@@/${DTB_PREFIX}/' \ "${WORKDIR}/boot.cmd.in" > boot.cmd mkimage -T script -C none -n "Distro boot script" -d boot.cmd boot.scr -- cgit v1.2.3