-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlinker.ld
More file actions
95 lines (81 loc) · 1.54 KB
/
linker.ld
File metadata and controls
95 lines (81 loc) · 1.54 KB
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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
/* Linker script */
/* entry point */
ENTRY( _start )
SECTIONS {
/* .init section, start code */
.init LOAD_ADDR : {
KEEP(*(.init))
}
/* .text section, program code */
.text : {
. = ALIGN(16);
*(.text*)
_etext = .;
}
/* .rodata section, initialized read-only data */
.rodata : {
. = ALIGN(16);
*(.rodata*)
}
/* static constructors of static objects, initialize arrays */
.init_array : {
. = ALIGN(16);
__init_start = .;
KEEP(*(.init_array*))
__init_end = .;
}
/* exception table to unwind stack */
.ARM.exidx : {
. = ALIGN(16);
__exidx_start = .;
*(.ARM.exidx*)
__exidx_end = .;
}
/* exception frames to unwind stack */
.eh_frame : {
. = ALIGN(16);
*(.eh_frame*)
}
/* .data section, initialized data */
.data : {
. = ALIGN(16);
*(.data*)
}
/* .bss section, uninitialized data */
.bss : {
. = ALIGN(16);
__bss_start = .;
*(.bss*)
*(COMMON)
__bss_end = .;
_end = .;
}
/* stack */
.stack (NOLOAD) : {
. = ALIGN(16);
__stack_start = .;
. = . + (CORES*CORE_STACK_SIZE);
__stack_end = .;
}
/* MMU table section */
.page_table (NOLOAD) : {
. = ALIGN(16384); /* 16 KB alignment */
*(.page_table_big)
. = ALIGN(4096);
*(.page_table_small)
. = ALIGN(16);
}
/* 2 MB coherent region - mailbox, DMA */
.coherent (NOLOAD) : {
. = ALIGN(2097152); /* 2 MB alignment */
__coherent_start = .;
*(.coherent)
__coherent_end = .;
. = ALIGN(2097152); /* 2 MB alignment */
}
/* .heap section */
.heap : {
. = ALIGN(2097152); /* 2 MB alignment */
__heap_start__ = .;
}
}