xref: /openbmc/u-boot/arch/arm/cpu/armv8/u-boot-spl.lds (revision 60570df1)
1/*
2 * (C) Copyright 2013
3 * David Feng <fenghua@phytium.com.cn>
4 *
5 * (C) Copyright 2002
6 * Gary Jennejohn, DENX Software Engineering, <garyj@denx.de>
7 *
8 * (C) Copyright 2010
9 * Texas Instruments, <www.ti.com>
10 *	Aneesh V <aneesh@ti.com>
11 *
12 * SPDX-License-Identifier:	GPL-2.0+
13 */
14
15MEMORY { .sram : ORIGIN = CONFIG_SPL_TEXT_BASE,
16		LENGTH = CONFIG_SPL_MAX_SIZE }
17MEMORY { .sdram : ORIGIN = CONFIG_SPL_BSS_START_ADDR,
18		LENGTH = CONFIG_SPL_BSS_MAX_SIZE }
19
20OUTPUT_FORMAT("elf64-littleaarch64", "elf64-littleaarch64", "elf64-littleaarch64")
21OUTPUT_ARCH(aarch64)
22ENTRY(_start)
23SECTIONS
24{
25	.text : {
26		. = ALIGN(8);
27		*(.__image_copy_start)
28		CPUDIR/start.o (.text*)
29		*(.text*)
30	} >.sram
31
32	.rodata : {
33		. = ALIGN(8);
34		*(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
35	} >.sram
36
37	.data : {
38		. = ALIGN(8);
39		*(.data*)
40	} >.sram
41
42	.u_boot_list : {
43		. = ALIGN(8);
44		KEEP(*(SORT(.u_boot_list*)));
45	} >.sram
46
47	.image_copy_end : {
48		. = ALIGN(8);
49		*(.__image_copy_end)
50	} >.sram
51
52	.end : {
53		. = ALIGN(8);
54		*(.__end)
55	} >.sram
56
57	.bss_start : {
58		. = ALIGN(8);
59		KEEP(*(.__bss_start));
60	} >.sdram
61
62	.bss : {
63		*(.bss*)
64		 . = ALIGN(8);
65	} >.sdram
66
67	.bss_end : {
68		KEEP(*(.__bss_end));
69	} >.sdram
70
71	/DISCARD/ : { *(.dynsym) }
72	/DISCARD/ : { *(.dynstr*) }
73	/DISCARD/ : { *(.dynamic*) }
74	/DISCARD/ : { *(.plt*) }
75	/DISCARD/ : { *(.interp*) }
76	/DISCARD/ : { *(.gnu*) }
77}
78