All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 1/2] recipes-bsp/u-boot: Allow deploying the u-boot DTB
@ 2021-06-06 17:05 Khem Raj
  2021-06-06 17:05 ` [PATCH v2 2/2] recipes-bsp/opensbi: Add support for specifying a device tree Khem Raj
  0 siblings, 1 reply; 2+ messages in thread
From: Khem Raj @ 2021-06-06 17:05 UTC (permalink / raw)
  To: openembedded-core; +Cc: Alistair Francis, Khem Raj, Richard Purdie

From: Alistair Francis <alistair.francis@wdc.com>

Use ??= assignment for UBOOT_DTB_BINARY because it is set using ?= in
fitImage bbclass as well, using ?= will preempt that

Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
v2: Fix test regression

 meta/classes/uboot-config.bbclass  | 4 ++++
 meta/recipes-bsp/u-boot/u-boot.inc | 7 ++++++-
 2 files changed, 10 insertions(+), 1 deletion(-)

diff --git a/meta/classes/uboot-config.bbclass b/meta/classes/uboot-config.bbclass
index 3bba02828b..451db0c650 100644
--- a/meta/classes/uboot-config.bbclass
+++ b/meta/classes/uboot-config.bbclass
@@ -71,6 +71,10 @@ UBOOT_MKIMAGE_SIGN ?= "${UBOOT_MKIMAGE}"
 UBOOT_MKIMAGE_SIGN_ARGS ?= ""
 SPL_MKIMAGE_SIGN_ARGS ?= ""
 
+# Options to deploy the u-boot device tree
+UBOOT_DTB ?= ""
+UBOOT_DTB_BINARY ??= ""
+
 python () {
     ubootmachine = d.getVar("UBOOT_MACHINE")
     ubootconfigflags = d.getVarFlags('UBOOT_CONFIG')
diff --git a/meta/recipes-bsp/u-boot/u-boot.inc b/meta/recipes-bsp/u-boot/u-boot.inc
index 5398c2e621..8ccc532f7e 100644
--- a/meta/recipes-bsp/u-boot/u-boot.inc
+++ b/meta/recipes-bsp/u-boot/u-boot.inc
@@ -5,7 +5,7 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
 
 DEPENDS += "kern-tools-native"
 
-inherit uboot-config uboot-extlinux-config uboot-sign deploy cml1 python3native
+inherit uboot-config uboot-extlinux-config uboot-sign deploy cml1 python3native kernel-arch
 
 DEPENDS += "swig-native"
 
@@ -346,6 +346,11 @@ do_deploy () {
         ln -sf ${UBOOT_EXTLINUX_SYMLINK} ${DEPLOYDIR}/${UBOOT_EXTLINUX_CONF_NAME}-${MACHINE}
         ln -sf ${UBOOT_EXTLINUX_SYMLINK} ${DEPLOYDIR}/${UBOOT_EXTLINUX_CONF_NAME}
     fi
+
+    if [ -n "${UBOOT_DTB}" ]
+    then
+        install -m 644 ${B}/arch/${UBOOT_ARCH}/dts/${UBOOT_DTB_BINARY} ${DEPLOYDIR}/
+    fi
 }
 
 addtask deploy before do_build after do_compile
-- 
2.31.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-06-06 17:05 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-06 17:05 [PATCH v2 1/2] recipes-bsp/u-boot: Allow deploying the u-boot DTB Khem Raj
2021-06-06 17:05 ` [PATCH v2 2/2] recipes-bsp/opensbi: Add support for specifying a device tree Khem Raj

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.