1 | /** |
---|
2 | * @file |
---|
3 | * |
---|
4 | * @ingroup bsp_linker |
---|
5 | * |
---|
6 | * @brief Linker command base file. |
---|
7 | */ |
---|
8 | |
---|
9 | /* |
---|
10 | * Copyright (c) 2011, 2016 embedded brains GmbH. All rights reserved. |
---|
11 | * |
---|
12 | * embedded brains GmbH |
---|
13 | * Dornierstr. 4 |
---|
14 | * 82178 Puchheim |
---|
15 | * Germany |
---|
16 | * <rtems@embedded-brains.de> |
---|
17 | * |
---|
18 | * The license and distribution terms for this file may be |
---|
19 | * found in the file LICENSE in this distribution or at |
---|
20 | * http://www.rtems.org/license/LICENSE. |
---|
21 | */ |
---|
22 | |
---|
23 | ENTRY (_start) |
---|
24 | STARTUP (start.o) |
---|
25 | |
---|
26 | /* |
---|
27 | * Global symbols that may be defined externally |
---|
28 | */ |
---|
29 | |
---|
30 | bsp_section_xbarrier_align = DEFINED (bsp_section_xbarrier_align) ? bsp_section_xbarrier_align : 1; |
---|
31 | bsp_section_robarrier_align = DEFINED (bsp_section_robarrier_align) ? bsp_section_robarrier_align : 1; |
---|
32 | bsp_section_rwbarrier_align = DEFINED (bsp_section_rwbarrier_align) ? bsp_section_rwbarrier_align : 1; |
---|
33 | |
---|
34 | MEMORY { |
---|
35 | UNEXPECTED_SECTIONS : ORIGIN = 0xffffffff, LENGTH = 0 |
---|
36 | } |
---|
37 | |
---|
38 | SECTIONS { |
---|
39 | .start : ALIGN_WITH_INPUT { |
---|
40 | bsp_section_start_begin = .; |
---|
41 | KEEP (*(.bsp_start_text)) |
---|
42 | KEEP (*(.bsp_start_data)) |
---|
43 | bsp_section_start_end = .; |
---|
44 | } > REGION_START AT > REGION_START |
---|
45 | bsp_section_start_size = bsp_section_start_end - bsp_section_start_begin; |
---|
46 | |
---|
47 | .xbarrier : ALIGN_WITH_INPUT { |
---|
48 | . = ALIGN (bsp_section_xbarrier_align); |
---|
49 | } > REGION_TEXT AT > REGION_TEXT |
---|
50 | |
---|
51 | .text : ALIGN_WITH_INPUT { |
---|
52 | bsp_section_text_begin = .; |
---|
53 | *(SORT(.bsp_text*)) |
---|
54 | *(.text.unlikely .text.*_unlikely) |
---|
55 | *(.text .stub .text.* .gnu.linkonce.t.*) |
---|
56 | *(.gnu.warning) |
---|
57 | *(.sfpr .glink) |
---|
58 | } > REGION_TEXT AT > REGION_TEXT_LOAD |
---|
59 | .init : ALIGN_WITH_INPUT { |
---|
60 | KEEP (*(.init)) |
---|
61 | } > REGION_TEXT AT > REGION_TEXT_LOAD |
---|
62 | .fini : ALIGN_WITH_INPUT { |
---|
63 | PROVIDE (_fini = .); |
---|
64 | KEEP (*(.fini)) |
---|
65 | bsp_section_text_end = .; |
---|
66 | } > REGION_TEXT AT > REGION_TEXT_LOAD |
---|
67 | bsp_section_text_size = bsp_section_text_end - bsp_section_text_begin; |
---|
68 | bsp_section_text_load_begin = LOADADDR (.text); |
---|
69 | bsp_section_text_load_end = bsp_section_text_load_begin + bsp_section_text_size; |
---|
70 | |
---|
71 | .fast_text : ALIGN_WITH_INPUT { |
---|
72 | bsp_section_fast_text_begin = .; |
---|
73 | *(.bsp_fast_text) |
---|
74 | bsp_section_fast_text_end = .; |
---|
75 | } > REGION_FAST_TEXT AT > REGION_FAST_TEXT_LOAD |
---|
76 | bsp_section_fast_text_size = bsp_section_fast_text_end - bsp_section_fast_text_begin; |
---|
77 | bsp_section_fast_text_load_begin = LOADADDR (.fast_text); |
---|
78 | bsp_section_fast_text_load_end = bsp_section_fast_text_load_begin + bsp_section_fast_text_size; |
---|
79 | |
---|
80 | .robarrier : ALIGN_WITH_INPUT { |
---|
81 | . = ALIGN (bsp_section_robarrier_align); |
---|
82 | } > REGION_RODATA AT > REGION_RODATA |
---|
83 | |
---|
84 | .rodata : ALIGN_WITH_INPUT { |
---|
85 | bsp_section_rodata_begin = .; |
---|
86 | *(SORT(.bsp_rodata*)) |
---|
87 | *(.rodata .rodata.* .gnu.linkonce.r.*) |
---|
88 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
89 | .rodata1 : ALIGN_WITH_INPUT { |
---|
90 | *(.rodata1) |
---|
91 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
92 | .sdata2 : ALIGN_WITH_INPUT { |
---|
93 | PROVIDE (_SDA2_BASE_ = 32768); |
---|
94 | *(.sdata2 .sdata2.* .gnu.linkonce.s2.*) |
---|
95 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
96 | .sbss2 : ALIGN_WITH_INPUT { |
---|
97 | *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*) |
---|
98 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
99 | .eh_frame_hdr : ALIGN_WITH_INPUT { |
---|
100 | *(.eh_frame_hdr) |
---|
101 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
102 | .eh_frame : ALIGN_WITH_INPUT { |
---|
103 | KEEP (*(.eh_frame)) |
---|
104 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
105 | .gcc_except_table : ALIGN_WITH_INPUT { |
---|
106 | *(.gcc_except_table .gcc_except_table.*) |
---|
107 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
108 | .tdata : ALIGN_WITH_INPUT { |
---|
109 | _TLS_Data_begin = .; |
---|
110 | *(.tdata .tdata.* .gnu.linkonce.td.*) |
---|
111 | _TLS_Data_end = .; |
---|
112 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
113 | .tbss : ALIGN_WITH_INPUT { |
---|
114 | _TLS_BSS_begin = .; |
---|
115 | *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) |
---|
116 | _TLS_BSS_end = .; |
---|
117 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
118 | _TLS_Data_size = _TLS_Data_end - _TLS_Data_begin; |
---|
119 | _TLS_Data_begin = _TLS_Data_size != 0 ? _TLS_Data_begin : _TLS_BSS_begin; |
---|
120 | _TLS_Data_end = _TLS_Data_size != 0 ? _TLS_Data_end : _TLS_BSS_begin; |
---|
121 | _TLS_BSS_size = _TLS_BSS_end - _TLS_BSS_begin; |
---|
122 | _TLS_Size = _TLS_BSS_end - _TLS_Data_begin; |
---|
123 | _TLS_Alignment = MAX (ALIGNOF (.tdata), ALIGNOF (.tbss)); |
---|
124 | .preinit_array : ALIGN_WITH_INPUT { |
---|
125 | PROVIDE_HIDDEN (__preinit_array_start = .); |
---|
126 | KEEP (*(.preinit_array)) |
---|
127 | PROVIDE_HIDDEN (__preinit_array_end = .); |
---|
128 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
129 | .init_array : ALIGN_WITH_INPUT { |
---|
130 | PROVIDE_HIDDEN (__init_array_start = .); |
---|
131 | KEEP (*(SORT(.init_array.*))) |
---|
132 | KEEP (*(.init_array)) |
---|
133 | PROVIDE_HIDDEN (__init_array_end = .); |
---|
134 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
135 | .fini_array : ALIGN_WITH_INPUT { |
---|
136 | PROVIDE_HIDDEN (__fini_array_start = .); |
---|
137 | KEEP (*(SORT(.fini_array.*))) |
---|
138 | KEEP (*(.fini_array)) |
---|
139 | PROVIDE_HIDDEN (__fini_array_end = .); |
---|
140 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
141 | .ctors : ALIGN_WITH_INPUT { |
---|
142 | KEEP (*ecrti.o(.ctors)) |
---|
143 | KEEP (*crtbegin.o(.ctors)) |
---|
144 | KEEP (*crtbegin?.o(.ctors)) |
---|
145 | KEEP (*(EXCLUDE_FILE (*crtend.o *crtend?.o *ecrtn.o) .ctors)) |
---|
146 | KEEP (*(SORT(.ctors.*))) |
---|
147 | KEEP (*(.ctors)) |
---|
148 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
149 | .dtors : ALIGN_WITH_INPUT { |
---|
150 | KEEP (*ecrti.o(.dtors)) |
---|
151 | KEEP (*crtbegin.o(.dtors)) |
---|
152 | KEEP (*crtbegin?.o(.dtors)) |
---|
153 | KEEP (*(EXCLUDE_FILE (*crtend.o *crtend?.o *ecrtn.o) .dtors)) |
---|
154 | KEEP (*(SORT(.dtors.*))) |
---|
155 | KEEP (*(.dtors)) |
---|
156 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
157 | .jcr : ALIGN_WITH_INPUT { |
---|
158 | KEEP (*(.jcr)) |
---|
159 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
160 | .data.rel.ro : ALIGN_WITH_INPUT { |
---|
161 | *(.data.rel.ro.local* .gnu.linkonce.d.rel.ro.local.*) *(.data.rel.ro* .gnu.linkonce.d.rel.ro.*) |
---|
162 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
163 | .fixup : ALIGN_WITH_INPUT { |
---|
164 | *(.fixup) |
---|
165 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
166 | .dynamic : ALIGN_WITH_INPUT { |
---|
167 | *(.dynamic) |
---|
168 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
169 | .opd : ALIGN_WITH_INPUT { |
---|
170 | KEEP (*(.opd)) |
---|
171 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
172 | .tm_clone_table : ALIGN_WITH_INPUT { |
---|
173 | *(.tm_clone_table) |
---|
174 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
175 | .toc1 : ALIGN_WITH_INPUT { |
---|
176 | *(.toc1) |
---|
177 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
178 | .branch_lt : ALIGN_WITH_INPUT { |
---|
179 | *(.branch_lt) |
---|
180 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
181 | .got1 : ALIGN_WITH_INPUT { |
---|
182 | *(.got1) |
---|
183 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
184 | .got2 : ALIGN_WITH_INPUT { |
---|
185 | *(.got2) |
---|
186 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
187 | .got : ALIGN_WITH_INPUT { |
---|
188 | *(.got) |
---|
189 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
190 | .toc : ALIGN_WITH_INPUT { |
---|
191 | *(.toc) |
---|
192 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
193 | .plt : ALIGN_WITH_INPUT { |
---|
194 | *(.plt) |
---|
195 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
196 | .iplt : ALIGN_WITH_INPUT { |
---|
197 | *(.iplt) |
---|
198 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
199 | .interp : ALIGN_WITH_INPUT { |
---|
200 | *(.interp) |
---|
201 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
202 | .note.gnu.build-id : ALIGN_WITH_INPUT { |
---|
203 | *(.note.gnu.build-id) |
---|
204 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
205 | .hash : ALIGN_WITH_INPUT { |
---|
206 | *(.hash) |
---|
207 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
208 | .gnu.hash : ALIGN_WITH_INPUT { |
---|
209 | *(.gnu.hash) |
---|
210 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
211 | .dynsym : ALIGN_WITH_INPUT { |
---|
212 | *(.dynsym) |
---|
213 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
214 | .dynstr : ALIGN_WITH_INPUT { |
---|
215 | *(.dynstr) |
---|
216 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
217 | .gnu.version : ALIGN_WITH_INPUT { |
---|
218 | *(.gnu.version) |
---|
219 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
220 | .gnu.version_d : ALIGN_WITH_INPUT { |
---|
221 | *(.gnu.version_d) |
---|
222 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
223 | .gnu.version_r : ALIGN_WITH_INPUT { |
---|
224 | *(.gnu.version_r) |
---|
225 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
226 | .rela.dyn : ALIGN_WITH_INPUT { |
---|
227 | *(.rela.init) |
---|
228 | *(.rela.text .rela.text.* .rela.gnu.linkonce.t.*) |
---|
229 | *(.rela.fini) |
---|
230 | *(.rela.rodata .rela.rodata.* .rela.gnu.linkonce.r.*) |
---|
231 | *(.rela.data .rela.data.* .rela.gnu.linkonce.d.*) |
---|
232 | *(.rela.tdata .rela.tdata.* .rela.gnu.linkonce.td.*) |
---|
233 | *(.rela.tbss .rela.tbss.* .rela.gnu.linkonce.tb.*) |
---|
234 | *(.rela.ctors) |
---|
235 | *(.rela.dtors) |
---|
236 | *(.rela.got) |
---|
237 | *(.rela.got1) |
---|
238 | *(.rela.got2) |
---|
239 | *(.rela.sdata .rela.sdata.* .rela.gnu.linkonce.s.*) |
---|
240 | *(.rela.sbss .rela.sbss.* .rela.gnu.linkonce.sb.*) |
---|
241 | *(.rela.sdata2 .rela.sdata2.* .rela.gnu.linkonce.s2.*) |
---|
242 | *(.rela.sbss2 .rela.sbss2.* .rela.gnu.linkonce.sb2.*) |
---|
243 | *(.rela.bss .rela.bss.* .rela.gnu.linkonce.b.*) |
---|
244 | *(.rela.rtemsroset*) |
---|
245 | *(.rela.rtemsrwset*) |
---|
246 | PROVIDE_HIDDEN (__rel_iplt_start = .); |
---|
247 | PROVIDE_HIDDEN (__rel_iplt_end = .); |
---|
248 | PROVIDE_HIDDEN (__rela_iplt_start = .); |
---|
249 | *(.rela.iplt) |
---|
250 | PROVIDE_HIDDEN (__rela_iplt_end = .); |
---|
251 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
252 | .rela.plt : ALIGN_WITH_INPUT { |
---|
253 | *(.rela.plt) |
---|
254 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
255 | .rtemsroset : ALIGN_WITH_INPUT { |
---|
256 | /* Special FreeBSD linker set sections */ |
---|
257 | __start_set_sysctl_set = .; |
---|
258 | *(set_sysctl_*); |
---|
259 | __stop_set_sysctl_set = .; |
---|
260 | *(set_domain_*); |
---|
261 | *(set_pseudo_*); |
---|
262 | |
---|
263 | KEEP (*(SORT(.rtemsroset.*))) |
---|
264 | bsp_section_rodata_end = .; |
---|
265 | } > REGION_RODATA AT > REGION_RODATA_LOAD |
---|
266 | bsp_section_rodata_size = bsp_section_rodata_end - bsp_section_rodata_begin; |
---|
267 | bsp_section_rodata_load_begin = LOADADDR (.rodata); |
---|
268 | bsp_section_rodata_load_end = bsp_section_rodata_load_begin + bsp_section_rodata_size; |
---|
269 | |
---|
270 | .rwbarrier : ALIGN_WITH_INPUT { |
---|
271 | . = ALIGN (bsp_section_rwbarrier_align); |
---|
272 | } > REGION_DATA AT > REGION_DATA |
---|
273 | |
---|
274 | .fast_data : ALIGN_WITH_INPUT { |
---|
275 | bsp_section_fast_data_begin = .; |
---|
276 | *(SORT(.bsp_fast_data*)) |
---|
277 | bsp_section_fast_data_end = .; |
---|
278 | } > REGION_FAST_DATA AT > REGION_FAST_DATA_LOAD |
---|
279 | bsp_section_fast_data_size = bsp_section_fast_data_end - bsp_section_fast_data_begin; |
---|
280 | bsp_section_fast_data_load_begin = LOADADDR (.fast_data); |
---|
281 | bsp_section_fast_data_load_end = bsp_section_fast_data_load_begin + bsp_section_fast_data_size; |
---|
282 | |
---|
283 | .data : ALIGN_WITH_INPUT { |
---|
284 | bsp_section_data_begin = .; |
---|
285 | *(SORT(.bsp_data*)) |
---|
286 | *(.data .data.* .gnu.linkonce.d.*) |
---|
287 | SORT(CONSTRUCTORS) |
---|
288 | } > REGION_DATA AT > REGION_DATA_LOAD |
---|
289 | .data1 : ALIGN_WITH_INPUT { |
---|
290 | *(.data1) |
---|
291 | } > REGION_DATA AT > REGION_DATA_LOAD |
---|
292 | .rtemsrwset : ALIGN_WITH_INPUT { |
---|
293 | KEEP (*(SORT(.rtemsrwset.*))) |
---|
294 | } > REGION_DATA AT > REGION_DATA_LOAD |
---|
295 | .sdata : ALIGN_WITH_INPUT { |
---|
296 | bsp_section_sdata_begin = .; |
---|
297 | PROVIDE (_SDA_BASE_ = 32768); |
---|
298 | *(.sdata .sdata.* .gnu.linkonce.s.*) |
---|
299 | bsp_section_sdata_end = .; |
---|
300 | bsp_section_data_end = .; |
---|
301 | } > REGION_DATA AT > REGION_DATA_LOAD |
---|
302 | bsp_section_sdata_size = bsp_section_sdata_end - bsp_section_sdata_begin; |
---|
303 | bsp_section_data_size = bsp_section_data_end - bsp_section_data_begin; |
---|
304 | bsp_section_data_load_begin = LOADADDR (.data); |
---|
305 | bsp_section_data_load_end = bsp_section_data_load_begin + bsp_section_data_size; |
---|
306 | |
---|
307 | /* |
---|
308 | * Set bsp_section_set_sdata_bss_size to the system's sdata and bss data size, eg: |
---|
309 | * |
---|
310 | * bsp_section_set_sdata_sbss_size = 65536; |
---|
311 | */ |
---|
312 | bsp_section_sdata_sbss_size = DEFINED(bsp_section_set_sdata_sbss_size) ? |
---|
313 | bsp_section_set_sdata_sbss_size : 0; |
---|
314 | .sbss : ALIGN_WITH_INPUT { |
---|
315 | bsp_section_sbss_begin = .; |
---|
316 | *(.dynsbss) |
---|
317 | *(.sbss .sbss.* .gnu.linkonce.sb.*) |
---|
318 | *(.scommon) |
---|
319 | bsp_section_sbss_end = .; |
---|
320 | bsp_section_sdata_libdl_begin = .; |
---|
321 | . += bsp_section_sdata_sbss_size - (bsp_section_sdata_size + bsp_section_sbss_size); |
---|
322 | bsp_section_sdata_libdl_end = .; |
---|
323 | } > REGION_DATA AT > REGION_DATA |
---|
324 | bsp_section_sbss_size = bsp_section_sbss_end - bsp_section_sbss_begin; |
---|
325 | |
---|
326 | .bss : ALIGN_WITH_INPUT { |
---|
327 | bsp_section_bss_begin = .; |
---|
328 | *(.dynbss) |
---|
329 | *(.bss .bss.* .gnu.linkonce.b.*) |
---|
330 | *(COMMON) |
---|
331 | bsp_section_bss_end = .; |
---|
332 | } > REGION_BSS AT > REGION_BSS |
---|
333 | bsp_section_bss_size = bsp_section_bss_end - bsp_section_bss_begin; |
---|
334 | |
---|
335 | .rtemsstack (NOLOAD) : ALIGN_WITH_INPUT { |
---|
336 | bsp_section_rtemsstack_begin = .; |
---|
337 | *(SORT(.rtemsstack.*)) |
---|
338 | bsp_section_rtemsstack_end = .; |
---|
339 | } > REGION_RTEMSSTACK AT > REGION_RTEMSSTACK |
---|
340 | bsp_section_rtemsstack_size = bsp_section_rtemsstack_end - bsp_section_rtemsstack_begin; |
---|
341 | |
---|
342 | .work : ALIGN_WITH_INPUT { |
---|
343 | /* |
---|
344 | * The work section will occupy the remaining REGION_WORK region and |
---|
345 | * contains the RTEMS work space and heap. |
---|
346 | */ |
---|
347 | bsp_section_work_begin = .; |
---|
348 | . += ORIGIN (REGION_WORK) + LENGTH (REGION_WORK) - ABSOLUTE (.); |
---|
349 | bsp_section_work_end = .; |
---|
350 | } > REGION_WORK AT > REGION_WORK |
---|
351 | bsp_section_work_size = bsp_section_work_end - bsp_section_work_begin; |
---|
352 | |
---|
353 | .stack : ALIGN_WITH_INPUT { |
---|
354 | /* |
---|
355 | * The stack section will occupy the remaining REGION_STACK region and may |
---|
356 | * contain the task stacks. Depending on the region distribution this |
---|
357 | * section may be of zero size. |
---|
358 | */ |
---|
359 | bsp_section_stack_begin = .; |
---|
360 | . += ORIGIN (REGION_STACK) + LENGTH (REGION_STACK) - ABSOLUTE (.); |
---|
361 | bsp_section_stack_end = .; |
---|
362 | } > REGION_STACK AT > REGION_STACK |
---|
363 | bsp_section_stack_size = bsp_section_stack_end - bsp_section_stack_begin; |
---|
364 | |
---|
365 | .nocache : ALIGN_WITH_INPUT { |
---|
366 | bsp_section_nocache_begin = .; |
---|
367 | *(SORT_BY_ALIGNMENT (SORT_BY_NAME (.bsp_nocache*))) |
---|
368 | bsp_section_nocache_end = .; |
---|
369 | } > REGION_NOCACHE AT > REGION_NOCACHE_LOAD |
---|
370 | bsp_section_nocache_size = bsp_section_nocache_end - bsp_section_nocache_begin; |
---|
371 | bsp_section_nocache_load_begin = LOADADDR (.nocache); |
---|
372 | bsp_section_nocache_load_end = bsp_section_nocache_load_begin + bsp_section_nocache_size; |
---|
373 | |
---|
374 | .nocachenoload (NOLOAD) : ALIGN_WITH_INPUT { |
---|
375 | bsp_section_nocachenoload_begin = .; |
---|
376 | *(SORT_BY_ALIGNMENT (SORT_BY_NAME (.bsp_noload_nocache*))) |
---|
377 | bsp_section_nocacheheap_begin = .; |
---|
378 | . += ORIGIN (REGION_NOCACHE) + LENGTH (REGION_NOCACHE) - ABSOLUTE (.); |
---|
379 | bsp_section_nocacheheap_end = .; |
---|
380 | bsp_section_nocachenoload_end = .; |
---|
381 | } > REGION_NOCACHE AT > REGION_NOCACHE |
---|
382 | bsp_section_nocacheheap_size = bsp_section_nocacheheap_end - bsp_section_nocacheheap_begin; |
---|
383 | bsp_section_nocachenoload_size = bsp_section_nocachenoload_end - bsp_section_nocachenoload_begin; |
---|
384 | |
---|
385 | .nvram (NOLOAD) : ALIGN_WITH_INPUT { |
---|
386 | bsp_section_nvram_begin = .; |
---|
387 | *(SORT_BY_ALIGNMENT (SORT_BY_NAME (.bsp_nvram*))) |
---|
388 | bsp_section_nvram_end = .; |
---|
389 | } > REGION_NVRAM AT > REGION_NVRAM |
---|
390 | bsp_section_nvram_size = bsp_section_nvram_end - bsp_section_nvram_begin; |
---|
391 | |
---|
392 | /* FIXME */ |
---|
393 | RamBase = ORIGIN (REGION_WORK); |
---|
394 | RamSize = LENGTH (REGION_WORK); |
---|
395 | WorkAreaBase = bsp_section_work_begin; |
---|
396 | HeapSize = 0; |
---|
397 | |
---|
398 | /* Stabs debugging sections. */ |
---|
399 | .stab 0 : { *(.stab) } |
---|
400 | .stabstr 0 : { *(.stabstr) } |
---|
401 | .stab.excl 0 : { *(.stab.excl) } |
---|
402 | .stab.exclstr 0 : { *(.stab.exclstr) } |
---|
403 | .stab.index 0 : { *(.stab.index) } |
---|
404 | .stab.indexstr 0 : { *(.stab.indexstr) } |
---|
405 | .comment 0 : { *(.comment) } |
---|
406 | /* DWARF debug sections. |
---|
407 | Symbols in the DWARF debugging sections are relative to the beginning |
---|
408 | of the section so we begin them at 0. */ |
---|
409 | /* DWARF 1 */ |
---|
410 | .debug 0 : { *(.debug) } |
---|
411 | .line 0 : { *(.line) } |
---|
412 | /* GNU DWARF 1 extensions */ |
---|
413 | .debug_srcinfo 0 : { *(.debug_srcinfo) } |
---|
414 | .debug_sfnames 0 : { *(.debug_sfnames) } |
---|
415 | /* DWARF 1.1 and DWARF 2 */ |
---|
416 | .debug_aranges 0 : { *(.debug_aranges) } |
---|
417 | .debug_pubnames 0 : { *(.debug_pubnames) } |
---|
418 | /* DWARF 2 */ |
---|
419 | .debug_info 0 : { *(.debug_info .gnu.linkonce.wi.*) } |
---|
420 | .debug_abbrev 0 : { *(.debug_abbrev) } |
---|
421 | .debug_line 0 : { *(.debug_line .debug_line.* .debug_line_end ) } |
---|
422 | .debug_frame 0 : { *(.debug_frame) } |
---|
423 | .debug_str 0 : { *(.debug_str) } |
---|
424 | .debug_loc 0 : { *(.debug_loc) } |
---|
425 | .debug_macinfo 0 : { *(.debug_macinfo) } |
---|
426 | /* SGI/MIPS DWARF 2 extensions */ |
---|
427 | .debug_weaknames 0 : { *(.debug_weaknames) } |
---|
428 | .debug_funcnames 0 : { *(.debug_funcnames) } |
---|
429 | .debug_typenames 0 : { *(.debug_typenames) } |
---|
430 | .debug_varnames 0 : { *(.debug_varnames) } |
---|
431 | /* DWARF 3 */ |
---|
432 | .debug_pubtypes 0 : { *(.debug_pubtypes) } |
---|
433 | .debug_ranges 0 : { *(.debug_ranges) } |
---|
434 | /* DWARF Extension. */ |
---|
435 | .debug_macro 0 : { *(.debug_macro) } |
---|
436 | .gnu.attributes 0 : { KEEP (*(.gnu.attributes)) } |
---|
437 | .PPC.EMB.apuinfo 0 : { *(.PPC.EMB.apuinfo) } |
---|
438 | /DISCARD/ : { *(.note.GNU-stack) *(.gnu_debuglink) *(.gnu.lto_*) } |
---|
439 | |
---|
440 | /* |
---|
441 | * This is a RTEMS specific section to catch all unexpected input |
---|
442 | * sections. In case you get an error like |
---|
443 | * "section `.unexpected_sections' will not fit in region |
---|
444 | * `UNEXPECTED_SECTIONS'" |
---|
445 | * you have to figure out the offending input section and add it to the |
---|
446 | * appropriate output section definition above. |
---|
447 | */ |
---|
448 | .unexpected_sections : { *(*) } > UNEXPECTED_SECTIONS |
---|
449 | } |
---|