Skip to contentSkip to conversation

boot/uboot/uboot.mk: fix zynqmp without pmufw

PATCH In review Brandon Maier via buildroot 2 participants 5 messages Nov 22, 2022 – Nov 26, 2022

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 boot/uboot/uboot.mk: fix zynqmp without pmufw

Commit d07e6b70 (boot/uboot/uboot.mk: add pmufw.elf support) broke configurations where the UBOOT_ZYNQMP_PMUFW was blank. Previously it would set the U-Boot CONFIG_PMUFW_INIT_FILE to the blank string, but now it will set it to ".bin" which causes U-Boot to fail to build.

---
v2:
- support pmufw with any extension

---
 boot/uboot/uboot.mk | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
boot/uboot/uboot.mk +3 -2
index 19e4183927..d037ae9c12 100644
@@ -394,8 +394,9 @@ UBOOT_ZYNQMP_PMUFW_BASENAME = $(basename $(UBOOT_ZYNQMP_PMUFW_PATH))
 
 define UBOOT_ZYNQMP_KCONFIG_PMUFW
 	$(if $(filter %.elf,$(UBOOT_ZYNQMP_PMUFW_PATH)),
-		objcopy -O binary -I elf32-little $(UBOOT_ZYNQMP_PMUFW_BASENAME).elf $(UBOOT_ZYNQMP_PMUFW_BASENAME).bin)
-	$(call KCONFIG_SET_OPT,CONFIG_PMUFW_INIT_FILE,"$(UBOOT_ZYNQMP_PMUFW_BASENAME).bin")
+		objcopy -O binary -I elf32-little $(UBOOT_ZYNQMP_PMUFW_BASENAME).elf $(UBOOT_ZYNQMP_PMUFW_BASENAME).bin
+		$(call KCONFIG_SET_OPT,CONFIG_PMUFW_INIT_FILE,"$(UBOOT_ZYNQMP_PMUFW_BASENAME).bin"),
+		$(call KCONFIG_SET_OPT,CONFIG_PMUFW_INIT_FILE,"$(UBOOT_ZYNQMP_PMUFW_PATH)"))
 endef
 
 UBOOT_ZYNQMP_PM_CFG = $(call qstrip,$(BR2_TARGET_UBOOT_ZYNQMP_PM_CFG))
Signature · 6 lines
2.38.1

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
author Reviewed-by Luca Ceresoli on v2 1/1
#1 lore raw

Hi Brandon,

Quoted 18 lines · On Tue, 22 Nov 2022 14:17:01 -0600 Brandon Maier <[email protected]>…

Commit d07e6b70 (boot/uboot/uboot.mk: add pmufw.elf support) broke configurations where the UBOOT_ZYNQMP_PMUFW was blank. Previously it would set the U-Boot CONFIG_PMUFW_INIT_FILE to the blank string, but now it will set it to ".bin" which causes U-Boot to fail to build.

---
v2:
- support pmufw with any extension

---
 boot/uboot/uboot.mk | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
boot/uboot/uboot.mk +0 -0
index 19e4183927..d037ae9c12 100644

boot/uboot/uboot.mk UBOOT_ZYNQMP_PMUFW_BASENAME = $(basename $(UBOOT_ZYNQMP_PMUFW_PATH)) · line 400

Quoted 9 lines
boot/uboot/uboot.mk +3 -2
@@ -394,8 +394,9 @@ UBOOT_ZYNQMP_PMUFW_BASENAME = $(basename $(UBOOT_ZYNQMP_PMUFW_PATH))
 
 define UBOOT_ZYNQMP_KCONFIG_PMUFW
 	$(if $(filter %.elf,$(UBOOT_ZYNQMP_PMUFW_PATH)),
-		objcopy -O binary -I elf32-little $(UBOOT_ZYNQMP_PMUFW_BASENAME).elf $(UBOOT_ZYNQMP_PMUFW_BASENAME).bin)
-	$(call KCONFIG_SET_OPT,CONFIG_PMUFW_INIT_FILE,"$(UBOOT_ZYNQMP_PMUFW_BASENAME).bin")
+		objcopy -O binary -I elf32-little $(UBOOT_ZYNQMP_PMUFW_BASENAME).elf $(UBOOT_ZYNQMP_PMUFW_BASENAME).bin
+		$(call KCONFIG_SET_OPT,CONFIG_PMUFW_INIT_FILE,"$(UBOOT_ZYNQMP_PMUFW_BASENAME).bin"),
+		$(call KCONFIG_SET_OPT,CONFIG_PMUFW_INIT_FILE,"$(UBOOT_ZYNQMP_PMUFW_PATH)"))
 endef

Using the else branche of $(if) is different from what I had in mind, but it is fine as well.

Thanks!

Signature · 7 lines
Luca Ceresoli, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
author Reviewed-by Neal Frager on v2 1/1
#2 lore raw
In reply to Brandon Maier via buildroot

Commit d07e6b70 (boot/uboot/uboot.mk: add pmufw.elf support) broke configurations where the UBOOT_ZYNQMP_PMUFW was blank. Previously it would set the U-Boot CONFIG_PMUFW_INIT_FILE to the blank string, but now it will set it to ".bin" which causes U-Boot to fail to build.

---
v2:
- support pmufw with any extension

---
 boot/uboot/uboot.mk | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
boot/uboot/uboot.mk +4 -2
@@ -394,8 +394,9 @@ UBOOT_ZYNQMP_PMUFW_BASENAME = $(basename $(UBOOT_ZYNQMP_PMUFW_PATH))
 
 define UBOOT_ZYNQMP_KCONFIG_PMUFW
 	$(if $(filter %.elf,$(UBOOT_ZYNQMP_PMUFW_PATH)),
-		objcopy -O binary -I elf32-little $(UBOOT_ZYNQMP_PMUFW_BASENAME).elf $(UBOOT_ZYNQMP_PMUFW_BASENAME).bin)
-	$(call KCONFIG_SET_OPT,CONFIG_PMUFW_INIT_FILE,"$(UBOOT_ZYNQMP_PMUFW_BASENAME).bin")
+		objcopy -O binary -I elf32-little $(UBOOT_ZYNQMP_PMUFW_BASENAME).elf $(UBOOT_ZYNQMP_PMUFW_BASENAME).bin
+		$(call KCONFIG_SET_OPT,CONFIG_PMUFW_INIT_FILE,"$(UBOOT_ZYNQMP_PMUFW_BASENAME).bin"),
+		$(call 
+KCONFIG_SET_OPT,CONFIG_PMUFW_INIT_FILE,"$(UBOOT_ZYNQMP_PMUFW_PATH)"))
 endef
 

UBOOT_ZYNQMP_PM_CFG = $(call qstrip,$(BR2_TARGET_UBOOT_ZYNQMP_PM_CFG))
--
2.38.1

Best regards,
Neal Frager
AMD

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot

#3 lore raw
In reply to Brandon Maier via buildroot
Quoted 11 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Brandon" == Brandon Maier <[email protected]> writes:

Commit d07e6b70 (boot/uboot/uboot.mk: add pmufw.elf support) broke configurations where the UBOOT_ZYNQMP_PMUFW was blank. Previously it would set the U-Boot CONFIG_PMUFW_INIT_FILE to the blank string, but now it will set it to ".bin" which causes U-Boot to fail to build.

---
v2:
- support pmufw with any extension

Committed, thanks.

Signature · 5 lines
Bye, Peter Korsgaard
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
#4 lore raw
Quoted 8 lines
Quoted 7 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

"Peter" == Peter Korsgaard <[email protected]> writes:

"Brandon" == Brandon Maier <[email protected]> writes:

Commit d07e6b70 (boot/uboot/uboot.mk: add pmufw.elf support) broke configurations where the UBOOT_ZYNQMP_PMUFW was blank. Previously it would set the U-Boot CONFIG_PMUFW_INIT_FILE to the blank string, but now it will set it to ".bin" which causes U-Boot to fail to build.

Quoted 4 lines
Quoted 4 lines

---
v2:
- support pmufw with any extension

Committed to 2022.08.x and 2022.02.x, thanks.

Signature · 5 lines
Bye, Peter Korsgaard
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot