-
Notifications
You must be signed in to change notification settings - Fork 0
/
linker.ld
74 lines (63 loc) · 1.04 KB
/
linker.ld
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
MEMORY
{
FLASH (RX) : ORIGIN = 0x00000000, LENGTH = 0x00003C00
CFG (R) : ORIGIN = 0x00003C00, LENGTH = 0x00003FF8
SRAM (RWX) : ORIGIN = 0x20000000, LENGTH = 0x00000800
BCR_CONFIG (R) : ORIGIN = 0x41C00000, LENGTH = 0x00000080
BSL_CONFIG (R) : ORIGIN = 0x41C00100, LENGTH = 0x00000080
}
ENTRY(reset_handler)
SECTIONS
{
.text :
{
KEEP(*(.vectors))
. = ALIGN(4);
*(.text*)
} >FLASH
.rodata :
{
*(.rodata*)
. = ALIGN(4);
_etext = .;
} >FLASH
.data :
{
_sdata = .;
KEEP(*(.data*))
. = ALIGN(4);
_edata = .;
} >SRAM AT> FLASH
.config (NOLOAD) :
{
_sconfig = .;
*(.config*)
. = ALIGN(8);
_econfig = .;
} >CFG
.bss :
{
_sbss = .;
*(.bss*)
. = ALIGN(4);
*(COMMON)
. = ALIGN(4);
_ebss = .;
} >SRAM
.noinit :
{
*(.noinit*)
. = ALIGN(4);
} >SRAM
_sstack = .;
PROVIDE(_estack = ORIGIN(SRAM) + LENGTH(SRAM));
.bcrconfig :
{
KEEP(*(.bcrconfig))
} >BCR_CONFIG
.bslconfig :
{
KEEP(*(.bslconfig))
} >BSL_CONFIG
}
_end = .;