diff options
| author | Chris Mason <c.mason@inchipdesign.com.au> | 2019-05-15 00:43:38 +1000 |
|---|---|---|
| committer | Damien George <damien.p.george@gmail.com> | 2019-06-14 15:29:24 +1000 |
| commit | 14cf91f70467aa928f3e17223f108ace0864b4fe (patch) | |
| tree | fdc70c3501e88d8c402d745923df30e243f059d9 /ports/stm32/stm32_it.c | |
| parent | 8b18cfedee441413d6b53a3d7c083a1e3a1a47e6 (diff) | |
stm32: In link script, define start of stack separately from heap end.
Previously the end of the heap was the start (lowest address) of the stack.
With the changes in this commit these addresses are now independent,
allowing a board to place the heap and stack in separate locations.
Diffstat (limited to 'ports/stm32/stm32_it.c')
| -rw-r--r-- | ports/stm32/stm32_it.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ports/stm32/stm32_it.c b/ports/stm32/stm32_it.c index 078b143bb..0c5263e05 100644 --- a/ports/stm32/stm32_it.c +++ b/ports/stm32/stm32_it.c @@ -181,7 +181,7 @@ void HardFault_C_Handler(ExceptionRegisters_t *regs) { if ((void*)&_ram_start <= (void*)regs && (void*)regs < (void*)&_ram_end) { mp_hal_stdout_tx_str("Stack:\r\n"); uint32_t *stack_top = &_estack; - if ((void*)regs < (void*)&_heap_end) { + if ((void*)regs < (void*)&_sstack) { // stack not in static stack area so limit the amount we print stack_top = (uint32_t*)regs + 32; } |
