Skip to content

Commit f324cee

Browse files
committed
hack to continue supporting two RAM regions
1 parent 4143c4d commit f324cee

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

cortex-m-rt/link.x

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,12 @@ SECTIONS
4949
} > FLASH
5050

5151
/* limits of the .stack region */
52-
_sstack = ORIGIN(RAM);
5352
_estack = _stack_start;
53+
/* HACK the `true` case indicates that two RAM regions are being used and
54+
/* that the stack was placed in the second region. In that case we don't know
55+
/* the size of the second RAM region, or its start address, so we just assume
56+
/* its zero sized */
57+
_sstack = _stack_start < ORIGIN(RAM)? _stack_start : ORIGIN(RAM);
5458

5559
/* fictitious region that represents the memory available for the stack */
5660
.stack _sstack (INFO) : ALIGN(4)

0 commit comments

Comments
 (0)