xref: /openbmc/u-boot/arch/arm/cpu/armv8/u-boot-spl.lds (revision e30d2bd4)
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	_image_binary_end = .;
58
59	.bss_start : {
60		. = ALIGN(8);
61		KEEP(*(.__bss_start));
62	} >.sdram
63
64	.bss : {
65		*(.bss*)
66		 . = ALIGN(8);
67	} >.sdram
68
69	.bss_end : {
70		KEEP(*(.__bss_end));
71	} >.sdram
72
73	/DISCARD/ : { *(.dynsym) }
74	/DISCARD/ : { *(.dynstr*) }
75	/DISCARD/ : { *(.dynamic*) }
76	/DISCARD/ : { *(.plt*) }
77	/DISCARD/ : { *(.interp*) }
78	/DISCARD/ : { *(.gnu*) }
79}
80