Skip to content

Commit

Permalink
Changed from specifying offset to specifying placement of .text
Browse files Browse the repository at this point in the history
  • Loading branch information
kjetilkjeka committed May 30, 2017
1 parent a88895f commit c3b5907
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions cortex-m-rt/link.x
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
text_offset = 0;

INCLUDE memory.x

SECTIONS
Expand All @@ -19,11 +17,14 @@ SECTIONS
_einterrupts = .;
} > FLASH

PROVIDE(_text_start = _einterrupts);
_reserved_size = _text_start - _einterrupts;

.reserved : ALIGN(4)
{
. += text_offset;
. += _reserved_size;
} > FLASH

.text : ALIGN(4)
{
/* Put reset handler first in .text section so it ends up as the entry */
Expand Down

0 comments on commit c3b5907

Please sign in to comment.