summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQuentin Schulz <quentin.schulz@cherry.de>2024-12-19 16:25:16 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2024-12-23 11:43:04 +0000
commitf9b1ca3001ee0309cff43ac3ec6206b7521df41a (patch)
tree2e7ebc128621705c6018b3bf901e435224837665
parent1da58e567915714619527976928e6b85a9eb4de0 (diff)
downloadpoky-f9b1ca3001ee0309cff43ac3ec6206b7521df41a.tar.gz
uboot-extlinux-config.bbclass: simplify FDT/FDTDIR logic
The three blocks share the same LABEL and KERNEL content, so let's factor that part out. (From OE-Core rev: bcc17523cf447a94571419662b55df3c197b4b44) Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de> Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/classes-recipe/uboot-extlinux-config.bbclass10
1 files changed, 4 insertions, 6 deletions
diff --git a/meta/classes-recipe/uboot-extlinux-config.bbclass b/meta/classes-recipe/uboot-extlinux-config.bbclass
index 0413e760bd..a6938ab063 100644
--- a/meta/classes-recipe/uboot-extlinux-config.bbclass
+++ b/meta/classes-recipe/uboot-extlinux-config.bbclass
@@ -137,14 +137,12 @@ python do_create_extlinux_config() {
137 137
138 fdt = localdata.getVar('UBOOT_EXTLINUX_FDT') 138 fdt = localdata.getVar('UBOOT_EXTLINUX_FDT')
139 139
140 cfgfile.write('LABEL %s\n\tKERNEL %s\n' % (menu_description, kernel_image))
141
140 if fdt: 142 if fdt:
141 cfgfile.write('LABEL %s\n\tKERNEL %s\n\tFDT %s\n' % 143 cfgfile.write('\tFDT %s\n' % (fdt))
142 (menu_description, kernel_image, fdt))
143 elif fdtdir: 144 elif fdtdir:
144 cfgfile.write('LABEL %s\n\tKERNEL %s\n\tFDTDIR %s\n' % 145 cfgfile.write('\tFDTDIR %s\n' % (fdtdir))
145 (menu_description, kernel_image, fdtdir))
146 else:
147 cfgfile.write('LABEL %s\n\tKERNEL %s\n' % (menu_description, kernel_image))
148 146
149 kernel_args = localdata.getVar('UBOOT_EXTLINUX_KERNEL_ARGS') 147 kernel_args = localdata.getVar('UBOOT_EXTLINUX_KERNEL_ARGS')
150 148