diff options
| author | Dario Nieuwenhuis <[email protected]> | 2023-02-19 23:00:16 +0100 |
|---|---|---|
| committer | Dario Nieuwenhuis <[email protected]> | 2023-02-19 23:02:31 +0100 |
| commit | 272982ee5417ea6bdd5873e36717ba9ae9a59ee4 (patch) | |
| tree | 1fdd40bf8082138412a43756f440c5788c4366f9 /examples | |
| parent | e3f8020c3bdf726dfa451b5b190f27191507a18f (diff) | |
examples/stm32wb: fix linker script.
cortex-m-rt 0.7.2 now enforces the stack is 8-byte aligned. Stack is placed
at `ORIGIN(RAM) + LENGTH(RAM)` by default, which wasn't 8-byte-aligned. See https://github.com/rust-embedded/cortex-m/discussions/469
ST trims 8 bytes from start of RAM, and uses the whole 192kb, so let's just
copy that:
https://github.com/STMicroelectronics/STM32CubeWB/blob/bceb1dae09f912eae47fba059251d499ba32f4ca/Drivers/CMSIS/Device/ST/STM32WBxx/Source/Templates/gcc/linker/stm32wb55xx_flash_cm4.ld#L48
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/stm32wb/memory.x | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/stm32wb/memory.x b/examples/stm32wb/memory.x index 2b4dcce34..ae14e5a12 100644 --- a/examples/stm32wb/memory.x +++ b/examples/stm32wb/memory.x | |||
| @@ -6,7 +6,7 @@ | |||
| 6 | MEMORY | 6 | MEMORY |
| 7 | { | 7 | { |
| 8 | FLASH (rx) : ORIGIN = 0x08000000, LENGTH = 256K | 8 | FLASH (rx) : ORIGIN = 0x08000000, LENGTH = 256K |
| 9 | RAM (xrw) : ORIGIN = 0x20000004, LENGTH = 191K | 9 | RAM (xrw) : ORIGIN = 0x20000008, LENGTH = 0x2FFF8 |
| 10 | RAM_SHARED (xrw) : ORIGIN = 0x20030000, LENGTH = 10K | 10 | RAM_SHARED (xrw) : ORIGIN = 0x20030000, LENGTH = 10K |
| 11 | } | 11 | } |
| 12 | 12 | ||
