diff mbox series

[v1,1/2] configs/zynqmp_zcu102_defconfig: fix pmufw sw reset

Message ID 20221017071002.48266-1-neal.frager@amd.com
State Accepted
Headers show
Series [v1,1/2] configs/zynqmp_zcu102_defconfig: fix pmufw sw reset | expand

Commit Message

Neal Frager Oct. 17, 2022, 7:10 a.m. UTC
This patch will solve the problem of the pmufw built by the
zynqmp-pmufw-builder where soft resets crash for the zcu102.
Details of the issue can be found here:

https://lore.kernel.org/buildroot/87ilqccu3k.fsf@dell.be.48ers.dk/

Signed-off-by: Neal Frager <neal.frager@amd.com>
---
 configs/zynqmp_zcu102_defconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Luca Ceresoli Oct. 17, 2022, 1:58 p.m. UTC | #1
On Mon, 17 Oct 2022 01:10:01 -0600
Neal Frager <neal.frager@amd.com> wrote:

> This patch will solve the problem of the pmufw built by the
> zynqmp-pmufw-builder where soft resets crash for the zcu102.
> Details of the issue can be found here:
> 
> https://lore.kernel.org/buildroot/87ilqccu3k.fsf@dell.be.48ers.dk/
> 
> Signed-off-by: Neal Frager <neal.frager@amd.com>
> ---
>  configs/zynqmp_zcu102_defconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/configs/zynqmp_zcu102_defconfig b/configs/zynqmp_zcu102_defconfig
> index 217fa0814b..66c24c4b64 100644
> --- a/configs/zynqmp_zcu102_defconfig
> +++ b/configs/zynqmp_zcu102_defconfig
> @@ -29,7 +29,7 @@ BR2_TARGET_UBOOT_NEEDS_OPENSSL=y
>  BR2_TARGET_UBOOT_SPL=y
>  BR2_TARGET_UBOOT_SPL_NAME="spl/boot.bin"
>  BR2_TARGET_UBOOT_ZYNQMP=y
> -BR2_TARGET_UBOOT_ZYNQMP_PMUFW="https://github.com/lucaceresoli/zynqmp-pmufw-binaries/raw/v2022.1/bin/pmufw-v2022.1.bin"
> +BR2_TARGET_UBOOT_ZYNQMP_PMUFW="https://github.com/Xilinx/ubuntu-firmware/raw/v2022.1_22.04_1/xlnx-firmware/zcu102/zcu102_pmufw.elf"

Why are these binaries board-specific? I thought this used to be only
needed for the "community workflow" before U-Boot SPL was able to load
a pmufw cfg object.
yegorslists--- via buildroot Oct. 17, 2022, 2:15 p.m. UTC | #2
Hi Luca,

> Why are these binaries board-specific? I thought this used to be only
> needed for the "community workflow" before U-Boot SPL was able to load
> a pmufw cfg object.

Good question!  I had a feeling you would ask this.

In the case of the zcu102, zcu104 and zcu106, the pmufw binary is not board specific.  The same pmufw binary will work on all 3 boards and even custom hardware, if a developer wants to use it unchanged.

But since the pmu reset gpios are customisable among other things, the kria kv260 actually uses a different pmufw configuration.  And developers may wish to modify the pmufw for their target as well.

Since the Xilinx firmware repository is created using the petalinux prebuilt images for each target hardware, we chose to have a pmufw.elf in each board directory to match what comes from the petalinux builds.

That said, since the Xilinx repository has a pmufw.elf in each individual board directory, I thought it would be cleaner for buildroot to use the pmufw.elf for each specific target.  Even if the zcu102 and zcu106 pmufw.elf binaries are really interchangeable.

What do you think?

Best regards,
Neal Frager
AMD
Luca Ceresoli Oct. 18, 2022, 7:04 a.m. UTC | #3
Hi Neal, Michal,

On Mon, 17 Oct 2022 14:15:16 +0000
"Frager, Neal" <neal.frager@amd.com> wrote:

> Hi Luca,
> 
> > Why are these binaries board-specific? I thought this used to be only
> > needed for the "community workflow" before U-Boot SPL was able to load
> > a pmufw cfg object.  
> 
> Good question!  I had a feeling you would ask this.

;-)

> In the case of the zcu102, zcu104 and zcu106, the pmufw binary is not board specific.  The same pmufw binary will work on all 3 boards and even custom hardware, if a developer wants to use it unchanged.

OK, I see. (@Michal) I compared the zcu102 and zcu106 binaries and they
are different, thus I wondered.

> But since the pmu reset gpios are customisable among other things, the kria kv260 actually uses a different pmufw configuration.  And developers may wish to modify the pmufw for their target as well.
> 
> Since the Xilinx firmware repository is created using the petalinux prebuilt images for each target hardware, we chose to have a pmufw.elf in each board directory to match what comes from the petalinux builds.

Sure, knowing the process clarifies the reason for having different
places for firmwares that are equivalent.

> That said, since the Xilinx repository has a pmufw.elf in each individual board directory, I thought it would be cleaner for buildroot to use the pmufw.elf for each specific target.  Even if the zcu102 and zcu106 pmufw.elf binaries are really interchangeable.

Sure it is.

Thank you both for the clarifications!

Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Peter Korsgaard Oct. 18, 2022, 7:41 p.m. UTC | #4
>>>>> "Neal" == Neal Frager <neal.frager@amd.com> writes:

 > This patch will solve the problem of the pmufw built by the
 > zynqmp-pmufw-builder where soft resets crash for the zcu102.
 > Details of the issue can be found here:

 > https://lore.kernel.org/buildroot/87ilqccu3k.fsf@dell.be.48ers.dk/

 > Signed-off-by: Neal Frager <neal.frager@amd.com>

Committed, thanks.
Peter Korsgaard Nov. 2, 2022, 10:57 p.m. UTC | #5
>>>>> "Neal" == Neal Frager <neal.frager@amd.com> writes:

 > This patch will solve the problem of the pmufw built by the
 > zynqmp-pmufw-builder where soft resets crash for the zcu102.
 > Details of the issue can be found here:

 > https://lore.kernel.org/buildroot/87ilqccu3k.fsf@dell.be.48ers.dk/

 > Signed-off-by: Neal Frager <neal.frager@amd.com>

Committed to 2022.08.x and 2022.02.x, thanks.
diff mbox series

Patch

diff --git a/configs/zynqmp_zcu102_defconfig b/configs/zynqmp_zcu102_defconfig
index 217fa0814b..66c24c4b64 100644
--- a/configs/zynqmp_zcu102_defconfig
+++ b/configs/zynqmp_zcu102_defconfig
@@ -29,7 +29,7 @@  BR2_TARGET_UBOOT_NEEDS_OPENSSL=y
 BR2_TARGET_UBOOT_SPL=y
 BR2_TARGET_UBOOT_SPL_NAME="spl/boot.bin"
 BR2_TARGET_UBOOT_ZYNQMP=y
-BR2_TARGET_UBOOT_ZYNQMP_PMUFW="https://github.com/lucaceresoli/zynqmp-pmufw-binaries/raw/v2022.1/bin/pmufw-v2022.1.bin"
+BR2_TARGET_UBOOT_ZYNQMP_PMUFW="https://github.com/Xilinx/ubuntu-firmware/raw/v2022.1_22.04_1/xlnx-firmware/zcu102/zcu102_pmufw.elf"
 BR2_TARGET_UBOOT_ZYNQMP_PM_CFG="board/zynqmp/zcu102/pm_cfg_obj.c"
 BR2_TARGET_UBOOT_FORMAT_ITB=y
 BR2_TARGET_UBOOT_NEEDS_ATF_BL31=y