-
Notifications
You must be signed in to change notification settings - Fork 6.9k
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
drivers: flash: stm32h7x: Fix wrong flash write offset #45639
drivers: flash: stm32h7x: Fix wrong flash write offset #45639
Conversation
76ebb65
to
06f7968
Compare
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.
LGTM.
@chrihell PR looks fine but please fix issues reported by the CI compliance check:
|
Add specific configuration and DTS overlay files for NUCLEO-H7A3ZI-Q board to the littlefs example project. The second half of the SOC flash is used as flash partition for littlefs. Signed-off-by: Christoph Heller <[email protected]>
The flash_stm32_write_range() function of the STM32H7x flash driver partially uses a wrong flash program word size for certain SOC types when calculating the flash write offset. If the used SOC is not having a flash program word size of 256 bits / 32 bytes the written data might get corrupted, as the flash write offset value does not match the number of bytes that were actually written. Fixes zephyrproject-rtos#45568 Signed-off-by: Christoph Heller <[email protected]>
06f7968
to
1ab18bd
Compare
Fixed CI compliance check errors. Hope it's fine now. Did I force push too much or was it ok like that? |
It's all good now, thank you! |
This PR fixes issue #45568
Changes:
Add specific configuration and DTS overlay files for NUCLEO-H7A3ZI-Q
board to the littlefs example project. The second half of the SOC flash
is used as flash partition for littlefs.
The flash_stm32_write_range() function of the STM32H7x flash
driver partially uses a wrong flash program word size for certain
SOC types when calculating the flash write offset. If the used
SOC is not having a flash program word size of 256 bits / 32 bytes
the written data might get corrupted, as the flash write offset
value does not match the number of bytes that were actually
written.
The fix was verified by executing the littlefs example application on a nucleo_h7a3zi_q board (uses SOC: STM32H7A3).
See issue for more details.