RTEMS | bsp/stm32f4: compute flash latency based on system clock (!1204)
Mohamed Ayman (@mohamedayman23)
gitlab at rtems.org
Thu Apr 16 10:38:14 UTC 2026
Mohamed Ayman created a merge request: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1204
Project:Branches: mohamedayman23/rtems:resolve-stm32f4-bspstart-TODO to rtems/rtos/rtems:main
Author: Mohamed Ayman
## bsp/stm32f4: compute flash latency based on system clock
Replace the hardcoded flash latency configuration with a calculation based on the system clock frequency.
The previous implementation always configured the flash latency to 5 wait states, which is only optimal for the highest supported clock frequencies. Lower system clock configurations could operate with fewer wait states, improving performance.
Introduce a helper function to determine the minimum required flash latency according to the STM32F4 reference manual and apply it during clock initialization before enabling the PLL.
This ensures correct and more efficient flash access timing across different system clock configurations.
{width=553 height=600}
AI Usage: None
AI Prompt: None
AI Model: None
How AI Used: Nono
--
View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1204
You're receiving this email because of your account on gitlab.rtems.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20260416/9e641c1f/attachment.htm>
More information about the bugs
mailing list