diff mbox series

[meta-rockchip,1/2] rockchip-extlinux.inc: handle multiple DTs in KERNEL_DEVICETREE

Message ID 20240522-nonfitdt-multi-dt-v1-1-c75dffd3aa7c@cherry.de
State New
Headers show
Series fix 2+ DTB in KERNEL_DEVICETREE and empty /boot without kernel-modules | expand

Commit Message

Quentin Schulz May 22, 2024, 6:26 p.m. UTC
From: Quentin Schulz <quentin.schulz@cherry.de>

KERNEL_DEVICETREE may contain more than one DTB, the first one being the
default one. Therefore, let's split on space first, to get the first DTB
before stripping the directory name from it.

This doesn't add support for creating multiple labels for each DTB in
KERNEL_DEVICETREE.

Fixes: 3b51866f2251 ("remove /boot partition")
Fixes: 13316b796814 ("KERNEL_DEVICETREE: 32-bit re-org")
Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de>
---
 conf/machine/include/rockchip-extlinux.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Trevor Woerner May 26, 2024, 1:37 p.m. UTC | #1
On Wed 2024-05-22 @ 08:26:43 PM, Quentin Schulz via lists.yoctoproject.org wrote:
> From: Quentin Schulz <quentin.schulz@cherry.de>
> 
> KERNEL_DEVICETREE may contain more than one DTB, the first one being the
> default one. Therefore, let's split on space first, to get the first DTB
> before stripping the directory name from it.
> 
> This doesn't add support for creating multiple labels for each DTB in
> KERNEL_DEVICETREE.
> 
> Fixes: 3b51866f2251 ("remove /boot partition")
> Fixes: 13316b796814 ("KERNEL_DEVICETREE: 32-bit re-org")
> Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de>
> ---
>  conf/machine/include/rockchip-extlinux.inc | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Reviewed-by: Trevor Woerner <twoerner@gmail.com>
Applied to meta-rockchip, master branch. Thanks!
diff mbox series

Patch

diff --git a/conf/machine/include/rockchip-extlinux.inc b/conf/machine/include/rockchip-extlinux.inc
index ca33f4c..10bb190 100644
--- a/conf/machine/include/rockchip-extlinux.inc
+++ b/conf/machine/include/rockchip-extlinux.inc
@@ -9,7 +9,7 @@ 
 # $UBOOT_EXTLINUX_FDTDIR/rockchip/$KERNEL_DEVICETREE but rather at
 # $UBOOT_EXTLINUX_FDTDIR/$KERNEL_DEVICETREE therefore we need to strip off
 # the 'rockchip/' part for extlinux non-fitImage builds
-NONFITDT ?= "${@d.getVar('KERNEL_DEVICETREE').split('/')[1]}"
+NONFITDT ?= "${@d.getVar('KERNEL_DEVICETREE').split()[0].split('/')[1]}"
 
 UBOOT_EXTLINUX ?= "1"
 UBOOT_EXTLINUX_ROOT ?= "root=PARTLABEL=root"