Message ID | 20240319070554.1323606-3-javad.rahimipetroudi@mind.be |
---|---|
State | Superseded |
Headers | show |
Series | [v3,1/3] configs/avenger96: bump Uboot version to 2024.01 | expand |
>>>>> "Javad" == Javad Rahimipetroudi <javad.rahimipetroudi@essensium.com> writes: > This patch upgrades the ATF version to v2.8. Please note that > due to DTS chages from commit 51e223058fe70b311542178f1865514745fa7874 > ("feat(stm32mp15-fdts): add Avenger96 board with STM32MP157A DHCOR SoM") > The ATF additional build variable also modified to use the new DTS file. > Signed-off-by: Javad Rahimipetroudi <javad.rahimipetroudi@mind.be> What about board/arrow/avenger96/patches/arm-trusted-firmware/0001-stm32mp157a-avenger96.dts-enable-hash-device-to-unbr.patch? Can that be dropped?
On 19/03/2024 08:05, Javad Rahimipetroudi wrote: > This patch upgrades the ATF version to v2.8. Please note that > due to DTS chages from commit 51e223058fe70b311542178f1865514745fa7874 > ("feat(stm32mp15-fdts): add Avenger96 board with STM32MP157A DHCOR SoM") > The ATF additional build variable also modified to use the new DTS file. I noticed that the old DTS file fdts/stm32mp157a-avenger96.dts still exists, but I suppose it doesn't actually work any more then? > Signed-off-by: Javad Rahimipetroudi <javad.rahimipetroudi@mind.be> > --- > configs/avenger96_defconfig | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/configs/avenger96_defconfig b/configs/avenger96_defconfig > index 98a71a0f25..67b6d16749 100644 > --- a/configs/avenger96_defconfig > +++ b/configs/avenger96_defconfig > @@ -29,13 +29,13 @@ BR2_TARGET_ROOTFS_EXT2_SIZE="120M" > # Bootloaders > BR2_TARGET_ARM_TRUSTED_FIRMWARE=y > BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION=y > -BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION_VALUE="v2.6" > +BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION_VALUE="v2.8" The intention was to be able to use BR2_TARGET_ARM_TRUSTED_FIRMWARE_LATEST_LTS_2_8_VERSION here, so that it gets updated automatically when the ATF LTS version is updated. For sure, v2.8 is not a good choice, because there's already a v2.8.16! > BR2_TARGET_ARM_TRUSTED_FIRMWARE_PLATFORM="stm32mp1" > BR2_TARGET_ARM_TRUSTED_FIRMWARE_FIP=y > BR2_TARGET_ARM_TRUSTED_FIRMWARE_BL31=y > BR2_TARGET_ARM_TRUSTED_FIRMWARE_UBOOT_AS_BL33=y > BR2_TARGET_ARM_TRUSTED_FIRMWARE_UBOOT_BL33_IMAGE="u-boot-nodtb.bin" > -BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_VARIABLES="STM32MP_SDMMC=1 AARCH32_SP=sp_min DTB_FILE_NAME=stm32mp157a-avenger96.dtb E=0 BL33_CFG=$(BINARIES_DIR)/u-boot.dtb" Please comment in the commit message on why E=0 is removed. It was added by Peter in deb8d71c9285eb60bc3d28e8abcf7208f78980a7 with this comment: Instead use v2.5 to match the other stm32mp1 boards and use the same E=0 -Werror workaround. The "the same" refers to commit 1c0c67fc1ae146b34475231fb702e7f2e6bf9f8f which has this comment: With the move to default to GCC 12 in commit e0091e42eef9 (package/gcc: switch to gcc 12.x as the default), TF-A now fails to build as a warning is generated and it builds with -Werror: CC plat/st/stm32mp1/bl2_plat_setup.c drivers/st/io/io_stm32image.c: In function ‘stm32image_partition_read’: drivers/st/io/io_stm32image.c:249:13: error: ‘result’ may be used uninitialized [-Werror=maybe-uninitialized] 249 | int result; | ^~~~~~ cc1: all warnings being treated as errors This is fixed in TF-A v2.6 with commit c1d732d0db24 (fix(io_stm32image): uninitialized variable warning), but I do not have the board to verify if v2.6 works, so instead disable -Werror by passsing E=0. So indeed, the E=0 is no longer necessary when we move to v2.6 or later, but this should be explained in the commit message. Regards, Arnout > +BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_VARIABLES="STM32MP_SDMMC=1 AARCH32_SP=sp_min DTB_FILE_NAME=stm32mp157a-dhcor-avenger96.dtb BL33_CFG=$(BINARIES_DIR)/u-boot.dtb" > BR2_TARGET_ARM_TRUSTED_FIRMWARE_IMAGES="fip.bin *.stm32" > BR2_TARGET_ARM_TRUSTED_FIRMWARE_NEEDS_DTC=y > BR2_TARGET_UBOOT=y
Hi Peter, On Tue, Mar 19, 2024 at 8:38 AM Peter Korsgaard <peter@korsgaard.com> wrote: > > >>>>> "Javad" == Javad Rahimipetroudi <javad.rahimipetroudi@essensium.com> writes: > > > This patch upgrades the ATF version to v2.8. Please note that > > due to DTS chages from commit 51e223058fe70b311542178f1865514745fa7874 > > ("feat(stm32mp15-fdts): add Avenger96 board with STM32MP157A DHCOR SoM") > > The ATF additional build variable also modified to use the new DTS file. > > > Signed-off-by: Javad Rahimipetroudi <javad.rahimipetroudi@mind.be> > > What about > board/arrow/avenger96/patches/arm-trusted-firmware/0001-stm32mp157a-avenger96.dts-enable-hash-device-to-unbr.patch? > Can that be dropped? > I think we can drop it. I will modify the commit. > -- > Bye, Peter Korsgaard Regards, Javad
Hi Arnout, On Tue, Mar 19, 2024 at 9:47 AM Arnout Vandecappelle <arnout@mind.be> wrote: > > > > On 19/03/2024 08:05, Javad Rahimipetroudi wrote: > > This patch upgrades the ATF version to v2.8. Please note that > > due to DTS chages from commit 51e223058fe70b311542178f1865514745fa7874 > > ("feat(stm32mp15-fdts): add Avenger96 board with STM32MP157A DHCOR SoM") > > The ATF additional build variable also modified to use the new DTS file. > > I noticed that the old DTS file fdts/stm32mp157a-avenger96.dts still exists, > but I suppose it doesn't actually work any more then? > Yes, we are using "stm32mp157a-dhcor-avenger96.dts". If "stm32mp157a-avenger96.dts" be used, the board will not board with the following error: NOTICE: CPU: STM32MP157AAC Rev.B NOTICE: Model: Arrow Electronics STM32MP157A Avenger96 board ERROR: nvmem node board_id not found ERROR: Product_below_2v5=1: ERROR: HSLVEN update is destructive, ERROR: no update as VDD > 2.7V PANIC at PC : 0x2ffee95d > > Signed-off-by: Javad Rahimipetroudi <javad.rahimipetroudi@mind.be> > > --- > > configs/avenger96_defconfig | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/configs/avenger96_defconfig b/configs/avenger96_defconfig > > index 98a71a0f25..67b6d16749 100644 > > --- a/configs/avenger96_defconfig > > +++ b/configs/avenger96_defconfig > > @@ -29,13 +29,13 @@ BR2_TARGET_ROOTFS_EXT2_SIZE="120M" > > # Bootloaders > > BR2_TARGET_ARM_TRUSTED_FIRMWARE=y > > BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION=y > > -BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION_VALUE="v2.6" > > +BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION_VALUE="v2.8" > > The intention was to be able to use > BR2_TARGET_ARM_TRUSTED_FIRMWARE_LATEST_LTS_2_8_VERSION here, so that it gets > updated automatically when the ATF LTS version is updated. > > For sure, v2.8 is not a good choice, because there's already a v2.8.16! Thanks, I will test and use lts-2.8.16 version. > > > BR2_TARGET_ARM_TRUSTED_FIRMWARE_PLATFORM="stm32mp1" > > BR2_TARGET_ARM_TRUSTED_FIRMWARE_FIP=y > > BR2_TARGET_ARM_TRUSTED_FIRMWARE_BL31=y > > BR2_TARGET_ARM_TRUSTED_FIRMWARE_UBOOT_AS_BL33=y > > BR2_TARGET_ARM_TRUSTED_FIRMWARE_UBOOT_BL33_IMAGE="u-boot-nodtb.bin" > > -BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_VARIABLES="STM32MP_SDMMC=1 AARCH32_SP=sp_min DTB_FILE_NAME=stm32mp157a-avenger96.dtb E=0 BL33_CFG=$(BINARIES_DIR)/u-boot.dtb" > > Please comment in the commit message on why E=0 is removed. It was added by > Peter in deb8d71c9285eb60bc3d28e8abcf7208f78980a7 with this comment: > > Instead use v2.5 to match the other stm32mp1 boards and use the same E=0 > -Werror workaround. > > The "the same" refers to commit 1c0c67fc1ae146b34475231fb702e7f2e6bf9f8f which > has this comment: > > With the move to default to GCC 12 in commit e0091e42eef9 (package/gcc: > switch to gcc 12.x as the default), TF-A now fails to build as a warning is > generated and it builds with -Werror: > > CC plat/st/stm32mp1/bl2_plat_setup.c > drivers/st/io/io_stm32image.c: In function ‘stm32image_partition_read’: > drivers/st/io/io_stm32image.c:249:13: error: ‘result’ may be used > uninitialized [-Werror=maybe-uninitialized] > 249 | int result; > | ^~~~~~ > cc1: all warnings being treated as errors > > This is fixed in TF-A v2.6 with commit c1d732d0db24 (fix(io_stm32image): > uninitialized variable warning), but I do not have the board to verify if > v2.6 works, so instead disable -Werror by passsing E=0. > > So indeed, the E=0 is no longer necessary when we move to v2.6 or later, but > this should be explained in the commit message. > Sure, I will add it in the commit > Regards, > Arnout > > > +BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_VARIABLES="STM32MP_SDMMC=1 AARCH32_SP=sp_min DTB_FILE_NAME=stm32mp157a-dhcor-avenger96.dtb BL33_CFG=$(BINARIES_DIR)/u-boot.dtb" > > BR2_TARGET_ARM_TRUSTED_FIRMWARE_IMAGES="fip.bin *.stm32" > > BR2_TARGET_ARM_TRUSTED_FIRMWARE_NEEDS_DTC=y > > BR2_TARGET_UBOOT=y Regards, Javad
>>>>> "Javad" == Javad Rahimipetroudi <javad.rahimipetroudi@essensium.com> writes: > Hi Arnout, > On Tue, Mar 19, 2024 at 9:47 AM Arnout Vandecappelle <arnout@mind.be> wrote: >> >> >> >> On 19/03/2024 08:05, Javad Rahimipetroudi wrote: >> > This patch upgrades the ATF version to v2.8. Please note that >> > due to DTS chages from commit 51e223058fe70b311542178f1865514745fa7874 >> > ("feat(stm32mp15-fdts): add Avenger96 board with STM32MP157A DHCOR SoM") >> > The ATF additional build variable also modified to use the new DTS file. >> >> I noticed that the old DTS file fdts/stm32mp157a-avenger96.dts still exists, >> but I suppose it doesn't actually work any more then? >> > Yes, we are using "stm32mp157a-dhcor-avenger96.dts". If > "stm32mp157a-avenger96.dts" > be used, the board will not board with the following error: > NOTICE: CPU: STM32MP157AAC Rev.B > NOTICE: Model: Arrow Electronics STM32MP157A Avenger96 board > ERROR: nvmem node board_id not found > ERROR: Product_below_2v5=1: > ERROR: HSLVEN update is destructive, > ERROR: no update as VDD > 2.7V > PANIC at PC : 0x2ffee95d Which seems to match: commit deb8d71c9285eb60bc3d28e8abcf7208f78980a7 Author: Peter Korsgaard <peter@korsgaard.com> Date: Sun Nov 5 19:37:19 2023 +0100 configs/avenger96_defconfig: downgrade to TF-A v2.5 Commit 27bf08e4addb78 (configs/avenger96_defconfig: bump ATF version to 2.9 for binutils 2.39+ support) bumped TF-A, but it unfortunately does not boot and instead dies with a panic: NOTICE: CPU: STM32MP157AAC Rev.B NOTICE: Model: Arrow Electronics STM32MP157A Avenger96 board ERROR: nvmem node board_id not found INFO: PMIC version = 0x10 ERROR: Product_below_2v5=1: ERROR: HSLVEN update is destructive, ERROR: no update as VDD > 2.7V PANIC at PC : 0x2fff086f Exception mode=0x00000016 at: 0x2fff086f
diff --git a/configs/avenger96_defconfig b/configs/avenger96_defconfig index 98a71a0f25..67b6d16749 100644 --- a/configs/avenger96_defconfig +++ b/configs/avenger96_defconfig @@ -29,13 +29,13 @@ BR2_TARGET_ROOTFS_EXT2_SIZE="120M" # Bootloaders BR2_TARGET_ARM_TRUSTED_FIRMWARE=y BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION=y -BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION_VALUE="v2.6" +BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION_VALUE="v2.8" BR2_TARGET_ARM_TRUSTED_FIRMWARE_PLATFORM="stm32mp1" BR2_TARGET_ARM_TRUSTED_FIRMWARE_FIP=y BR2_TARGET_ARM_TRUSTED_FIRMWARE_BL31=y BR2_TARGET_ARM_TRUSTED_FIRMWARE_UBOOT_AS_BL33=y BR2_TARGET_ARM_TRUSTED_FIRMWARE_UBOOT_BL33_IMAGE="u-boot-nodtb.bin" -BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_VARIABLES="STM32MP_SDMMC=1 AARCH32_SP=sp_min DTB_FILE_NAME=stm32mp157a-avenger96.dtb E=0 BL33_CFG=$(BINARIES_DIR)/u-boot.dtb" +BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_VARIABLES="STM32MP_SDMMC=1 AARCH32_SP=sp_min DTB_FILE_NAME=stm32mp157a-dhcor-avenger96.dtb BL33_CFG=$(BINARIES_DIR)/u-boot.dtb" BR2_TARGET_ARM_TRUSTED_FIRMWARE_IMAGES="fip.bin *.stm32" BR2_TARGET_ARM_TRUSTED_FIRMWARE_NEEDS_DTC=y BR2_TARGET_UBOOT=y
This patch upgrades the ATF version to v2.8. Please note that due to DTS chages from commit 51e223058fe70b311542178f1865514745fa7874 ("feat(stm32mp15-fdts): add Avenger96 board with STM32MP157A DHCOR SoM") The ATF additional build variable also modified to use the new DTS file. Signed-off-by: Javad Rahimipetroudi <javad.rahimipetroudi@mind.be> --- configs/avenger96_defconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)