- Notifications
You must be signed in to change notification settings - Fork 68
STM32: Add missing patches #145
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
| Thanks @nandojve for this update. It seems cherry pick of commit 3d93882 is missing in your series. Also, cherry-picking commit "STM32U5 : update HAL on U5 to version 1.6.1" likely requires commit a567837 is reverted first. Also this last commit modifies the flash layout (48kB added in I think mainline commit d090f3cd53 should also be cherry picked. |
| Hi @etienne-lms , Could you revisit to check if sequence is on now. I'll start to work on the Zephyr PR to open ASAP. |
| Hi @etienne-lms , I'm not sure if we can keep below without decrease the S or NS size. The bootloader will increase to 272k which means that Or should I drop from NS ? |
| I would be in favor to decrease the NS partitions. In any case, this also means changing the flash layout in TF-M since the secondary partition (either for S and NS) needs to be updated. Actually, from TF-M/MCUBoot there is a unique size value defined for both primary and secondary partitions of a firmware (being either S or NS). Well well well, in the end, it seems we'll have to ask TF-M to update it's flash layout. |
| Hi @etienne-lms , Did you got some answers about the MCUboot partition size ? |
tomi-font left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why so many cherry picks are cherry picks of cherry picks? Couldn't we just cherry pick the original commit directly?
platform/ext/target/stm/b_u585i_iot02a/partition/flash_layout.h Outdated Show resolved Hide resolved
| The series almost looks good to me but I have a few comments. Coudl you remove the second In the same scope, fix the cherry-pick reference in commit "STM : Add STM32WBA && STM32U5 drivers to psa-arch-tests": -(cherry picked from commit b3be2a36bbd1f9ada9b42024f737ca1392630732) +(cherry picked from commit 30fae6a9003b7551f4ad98f0239b0bfcf97cd51d)Ditto for commit "STM32U5 : TFM doesn't work properly if NS enter/exit low power mode.": -(cherry picked from commit 666982fc83d3cbb269781e87359f29c890572fc0) +(cherry picked from commit b4f636eac270b07832ee0c50b7b719665103d6d4)Ditto for commit "STM32WBA6: fix C sources build warning in tfm_hal_platform.c": -(cherry picked from commit 5a8b7d5747ac043e0fd97a9add488bcb978ed7a7) +(cherry picked from commit f140e4d5810835b8138db410c389c4b87788f81b)Ditto for commit "STM32WBA: issue related to zephyr project.": -(cherry picked from commit 6df3ce1d69058af8c472621c9dcc4db8835db3b7) +(cherry picked from commit ec61e691a08bd21d15437ee2cff19f1d4688d5ee)Ditto for commit "STM : low_level_flash drivers doesn't disable icache": -(cherry picked from commit 992f9896ac5ba8da0b96ee76644902ef926a4983) +(cherry picked from commit a68b8117235f12568bfd31e9c14b1bf0a1e7f957)Regarding the 4 latest commits in your series, I would propose to discard them as for now and handle them in a dedicated P-R:
If you really want these 4 commits to be merged:
Last, there is also another commit that needs to be picked for WBA65 support: |
| Hi @etienne-lms , Thank you for your precise review. I hope I did not forget anything.
This is not for U585 it is for U5A5, this is why you still can build without any issue.
Yes, we need to fix all the issues with U5xxx MCU in Zephyr. I'll provide the fixes on Zephyr side.
No worries, I'll add as many as necessary. Btw, this series still require the below (which I believe will land tomorrow in mainline): https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41827 I'll start to update Zephyr side to get ready. |
etienne-lms left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @nandojve, looks all good to me but some spurious 2nd Change-id: tags in a few commits (each time at last line of the commit message):
"STM32WBA6 : remove duplicated platform_bl2 directives",
"STM32WBA6 : disable MPU before its reconfigured",
"STM32WBA6 : remove unused BL2 macros",
"STM32WBA6: Split firmware and OTP binary images",
"STM32WBA6: Make flash offset gap configurable",
"STM32WBA6: fix typo on MCUBOOT_UPGRADE_STRATEGY config",
"STM32WBA: fix some issue.",
"STM : Add STM32WBA && STM32U5 drivers to psa-arch-tests",
"STM32U5 : TFM doesn't work properly if NS enter/exit low power mode.",
"STM32WBA6: fix C sources build warning in tfm_hal_platform.c",
"STM32WBA: issue related to zephyr project.",
"STM : low_level_flash drivers doesn't disable icache" and
"STM32U5 : update HAL on U5 to version 1.3.0".
With that addressed, you have my approval for the series.
Regarding the remaining changes you needs, let's wait they are merged in TF-M, which should happen soon as you said. If merged before this current P-R is merged, you can still add them to this series.
| Hi @etienne-lms , Thank you for review. I'll check again for those.
They got merged few hours ago. I'll review again and cherry-pick those. |
| Hi @etienne-lms , I update the series and remove the git hook that always add the change-id after I removed it. |
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
platform/ext/target/stm/b_u585i_iot02a/partition/flash_layout.h Outdated Show resolved Hide resolved
update regression.sh script to be compatible with flash_layout.h Change-Id: Ic4651000ac3c22f54f329d0e0aebb41ffb839b34 Signed-off-by: Ronan Gabou <ronan.gabou@st.com> (cherry picked from commit d985df0)
Re-names platform folder from stm32wba65i-dk to stm32wba65i_dk to align closer to other platforms. Change-Id: I7f14ea5be18a97031bf2f6f776bbdf2e2adeab8e Signed-off-by: Matthew Dalzell <matthew.dalzell@arm.com> (cherry picked from commit 3d93882)
Fix build warnings due to unused variables in a few C source files. Signed-off-by: Ahmad EL JOUAID <ahmad.eljouaid@st.com> Change-Id: If80baaf3f8c6905135924dafa0d2a2de9f82d536 (cherry picked from commit 6104cfc6f05f5a7b922d4bf64bddee54dd9f92f7)
The provision files are board dependent but are defined inside common CMakeLists.txt. This means that the current behaviour do not allow customize this values for Out of Tree buildings. This moves the definition to the board CMakeLists.txt to solve the issue. Change-Id: I6654fa7f61a3f7f33e65ac9b979e9224e009e8e9 Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com> (cherry picked from commit 845319f646659104524c840e76e398150f60ed60)
The provision files are board dependent but are defined inside common CMakeLists.txt. This means that the current behaviour do not allow customize this values for Out of Tree buildings. This moves the definition to the board CMakeLists.txt to solve the issue. Change-Id: I593c070f5fe9280c14c344aa49c89230383033dd Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com> (cherry picked from commit 62c51f68482511f13c5dc3c02d86f75d3c813ecb)
The otp_provision.c file is board dependent but is defined inside common CMakeLists.txt. This means that the current behaviour do not allow customize the value for Out of Tree building. This moves the definition to the board CMakeLists.txt to solve the issue. Change-Id: I8ed751c51c7e07182b620b5cfbe5af15a25cde9a Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com> (cherry picked from commit eb22a5b5fe3993d79e8217a737607cea9a1b044c)
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
| @nashif, @tomi-font Is there anything preventing this PR to be merged ? |
one the maintainers needs to merge, I only work here.... |
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
!!! WARNING: !!! Please, do not review this change. It is currently under review at: !!! zephyrproject-rtos#93520 This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
This brings many tf-m patches related to stm32 SoCs. It sync stm32 with the vendor mainline patches and add all the necessary pieces to allow STM32U5Axxx SoC work with TF-M. The patch list can be checked in: zephyrproject-rtos/trusted-firmware-m#145 In addition, redesign the b_u585i_iot02a flash partitions. The current b_u585i_iot02a NS flash layout difficult the development of large applications. Since there is an external NOR memory which is already supported by tf-m, this proposes a layout reconfiguration which allows bigger bootloader, S and NS software. With this redesign the overlay in the tests can be safely removed. This new layout is synced with TF-M 2.1.1 mainline, see: https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/41126 The bootloader BL2 now will fetch FOTA content from the external memory. Signed-off-by: BUDKE Gerson Fernando <gerson.budke@leica-geosystems.com>
Add missing STM patches.