Skip to contentSkip to conversation

Make 'bootefi' work again

ImageBuilder Michal Orzel 2 participants 2 messages Jul 16, 2024

lore
Share & tools
lore
#0 lore raw

When $BOOT_CMD is bootefi, there shall be no '-' between $kernel_addr and $device_tree_addr.

Fixes 3fa89f8f9853 ("Add support for BOOT_CMD")

---
Note: using this command would be a good opportunity for a Xen EFI boot CI test on Arm64 when the stub is not responsible for loading modules.

---
 scripts/uboot-script-gen | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
scripts/uboot-script-gen +1 -1
index 8b664e711b10..f8a087b881ce 100755
@@ -1391,7 +1391,7 @@ fi
 
 if [ "$BOOT_CMD" != "none" ]
 then
-    echo "$BOOT_CMD $kernel_addr - $device_tree_addr" >> $UBOOT_SOURCE
+    echo "$BOOT_CMD $kernel_addr $([ "$BOOT_CMD" = "bootefi" ] || echo '-') $device_tree_addr" >> $UBOOT_SOURCE
 else
     # skip boot command but store load addresses to be used later
     echo "setenv host_kernel_addr $kernel_addr" >> $UBOOT_SOURCE
Signature · 1 line
2.25.1
Reviewed-by
#1 lore raw
Quoted 5 lines · Michal Orzel

When $BOOT_CMD is bootefi, there shall be no '-' between $kernel_addr and $device_tree_addr.

Fixes 3fa89f8f9853 ("Add support for BOOT_CMD")

I think and if/else would have been more readable but it is fine anyway. Thanks for spotting the issue and fixing it quickly!

Quoted 23 lines

---
Note: using this command would be a good opportunity for a Xen EFI boot CI test on Arm64 when the stub is not responsible for loading modules.

---
 scripts/uboot-script-gen | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
scripts/uboot-script-gen +1 -1
index 8b664e711b10..f8a087b881ce 100755
@@ -1391,7 +1391,7 @@ fi
 
 if [ "$BOOT_CMD" != "none" ]
 then
-    echo "$BOOT_CMD $kernel_addr - $device_tree_addr" >> $UBOOT_SOURCE
+    echo "$BOOT_CMD $kernel_addr $([ "$BOOT_CMD" = "bootefi" ] || echo '-') $device_tree_addr" >> $UBOOT_SOURCE
 else
     # skip boot command but store load addresses to be used later
     echo "setenv host_kernel_addr $kernel_addr" >> $UBOOT_SOURCE
Signature · 1 line
2.25.1