xref: /openbmc/u-boot/arch/arm/mach-zynq/u-boot.lds (revision 78a88f79)
1/* SPDX-License-Identifier: GPL-2.0+ */
2/*
3 * Copyright (c) 2004-2008 Texas Instruments
4 *
5 * (C) Copyright 2002
6 * Gary Jennejohn, DENX Software Engineering, <garyj@denx.de>
7 */
8
9OUTPUT_FORMAT("elf32-littlearm", "elf32-littlearm", "elf32-littlearm")
10OUTPUT_ARCH(arm)
11ENTRY(_start)
12SECTIONS
13{
14	. = 0x00000000;
15
16	. = ALIGN(4);
17	.text :
18	{
19		*(.__image_copy_start)
20		*(.vectors)
21		CPUDIR/start.o (.text*)
22		*(.text*)
23	}
24
25	. = ALIGN(4);
26	.rodata : { *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*))) }
27
28	. = ALIGN(4);
29	.data : {
30		*(.data*)
31	}
32
33	. = ALIGN(4);
34
35	. = .;
36
37	. = ALIGN(4);
38	.u_boot_list : {
39		KEEP(*(SORT(.u_boot_list*)));
40	}
41
42	. = ALIGN(4);
43
44	.__efi_runtime_start : {
45		*(.__efi_runtime_start)
46	}
47
48	.efi_runtime : {
49		*(efi_runtime_text)
50		*(efi_runtime_data)
51	}
52
53	.__efi_runtime_stop : {
54		*(.__efi_runtime_stop)
55	}
56
57	.efi_runtime_rel_start :
58	{
59		*(.__efi_runtime_rel_start)
60	}
61
62	.efi_runtime_rel : {
63		*(.relefi_runtime_text)
64		*(.relefi_runtime_data)
65	}
66
67	.efi_runtime_rel_stop :
68	{
69		*(.__efi_runtime_rel_stop)
70	}
71
72	. = ALIGN(4);
73	.image_copy_end :
74	{
75		*(.__image_copy_end)
76	}
77
78	.rel_dyn_start :
79	{
80		*(.__rel_dyn_start)
81	}
82
83	.rel.dyn : {
84		*(.rel*)
85	}
86
87	.rel_dyn_end :
88	{
89		*(.__rel_dyn_end)
90	}
91
92	.end :
93	{
94		*(.__end)
95	}
96
97	_image_binary_end = .;
98
99/*
100 * Compiler-generated __bss_start and __bss_end, see arch/arm/lib/bss.c
101 * __bss_base and __bss_limit are for linker only (overlay ordering)
102 */
103
104	.bss_start __rel_dyn_start (OVERLAY) : {
105		KEEP(*(.__bss_start));
106		__bss_base = .;
107	}
108
109	.bss __bss_base (OVERLAY) : {
110		*(.bss*)
111		 . = ALIGN(4);
112		 __bss_limit = .;
113	}
114
115	.bss_end __bss_limit (OVERLAY) : {
116		KEEP(*(.__bss_end));
117	}
118
119	/*
120	 * Zynq needs to discard these sections because the user
121	 * is expected to pass this image on to tools for boot.bin
122	 * generation that require them to be dropped.
123	 */
124	/DISCARD/ : { *(.dynsym) }
125	/DISCARD/ : { *(.dynbss*) }
126	/DISCARD/ : { *(.dynstr*) }
127	/DISCARD/ : { *(.dynamic*) }
128	/DISCARD/ : { *(.plt*) }
129	/DISCARD/ : { *(.interp*) }
130	/DISCARD/ : { *(.gnu*) }
131	/DISCARD/ : { *(.ARM.exidx*) }
132	/DISCARD/ : { *(.gnu.linkonce.armexidx.*) }
133}
134