-
Notifications
You must be signed in to change notification settings - Fork 143
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[stm32] Place stack in SRAM by default on H7, add lbuild option
The DTCM is not DMA-capable on H7 devices. An lbuild option is added to select the stack location between SRAM and DTCM.
- Loading branch information
1 parent
605aaba
commit efb40cc
Showing
2 changed files
with
14 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
efb40cc
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.
This change in the file
modm/link/linkerscript.ld
in my project has been responsible for a hard fault:I believe this might have been caused by this commit.
Any ideas why that would have happened?
I used the lbuild option to bypass this issue, but I wonder if sram being the default wouldn't cause too much problem.
efb40cc
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.
cc @chris-durand
efb40cc
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.
That's really strange. The default was changed because the DTCM isn't accessible from most DMA instances. I don't see how that could cause a hardfault with the sram being less restrictive regarding what can access it.
@eduardobehr Could you try to figure out what kind of fault you have and what triggers it (https://interrupt.memfault.com/blog/cortex-m-hardfault-debug)?
efb40cc
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.
Guess what: I couldn't reproduce the issue this time...
If it happens again, I'll gather more debug info and get back to you.