Skip to content
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

hw/mcu/stm32: Fix WFI in RAM for -O3 #3296

Merged
merged 1 commit into from
Aug 19, 2024

Conversation

kasjer
Copy link
Contributor

@kasjer kasjer commented Aug 17, 2024

Even though function stm32_wfi_from_ram() has attribute to be placed in ram in -03 it can be inlined that can effectively run WFI from flash.

Now additional attribute is added to make sure that it is not inlined.

bx lr is also removed allowing compiler to make normal exit from function (which in most cases will be bx lr)

Even though function stm32_wfi_from_ram() has attribute
to be placed in ram in -03 it can be inlined that can
effectively run WFI from flash.

Now additional attribute is added to make sure that
it is not inlined.

bx lr is also removed allowing compiler to make normal
exit from function (which in most cases will be bx lr)

Signed-off-by: Jerzy Kasenberg <[email protected]>
@github-actions github-actions bot added STM STM32 related size/xs labels Aug 17, 2024
@kasjer kasjer merged commit ed30c61 into apache:master Aug 19, 2024
19 checks passed
@kasjer kasjer deleted the kasjer/stm32-wfi-from-ram-fix branch August 19, 2024 12:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size/xs STM STM32 related
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants