xref: /openbmc/u-boot/arch/mips/cpu/u-boot.lds (revision e3963c09)
1/* SPDX-License-Identifier: GPL-2.0+ */
2/*
3 * (C) Copyright 2003
4 * Wolfgang Denk Engineering, <wd@denx.de>
5 */
6
7OUTPUT_ARCH(mips)
8ENTRY(_start)
9SECTIONS
10{
11	. = 0x00000000;
12
13	. = ALIGN(4);
14	.text : {
15		__text_start = .;
16		*(.text*)
17		__text_end = .;
18	}
19
20	. = ALIGN(4);
21	.rodata : {
22		*(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
23	}
24
25	. = ALIGN(4);
26	.data : {
27		*(.data*)
28	}
29
30	. = ALIGN(4);
31	.sdata : {
32		*(.sdata*)
33	}
34
35	. = ALIGN(4);
36	.u_boot_list : {
37		KEEP(*(SORT(.u_boot_list*)));
38	}
39
40	. = ALIGN(4);
41	__image_copy_end = .;
42	__init_end = .;
43
44	.data.reloc : {
45		__rel_start = .;
46		/*
47		 * Space for relocation table
48		 * This needs to be filled so that the
49		 * mips-reloc tool can overwrite the content.
50		 * An invalid value is left at the start of the
51		 * section to abort relocation if the table
52		 * has not been filled in.
53		 */
54		LONG(0xFFFFFFFF);
55		FILL(0);
56		. += CONFIG_MIPS_RELOCATION_TABLE_SIZE - 4;
57	}
58
59	. = ALIGN(4);
60	_end = .;
61
62	.bss __rel_start (OVERLAY) : {
63		__bss_start = .;
64		*(.sbss.*)
65		*(.bss.*)
66		*(COMMON)
67		. = ALIGN(4);
68		__bss_end = .;
69	}
70
71	.dynsym _end : {
72		*(.dynsym)
73	}
74
75	.dynbss : {
76		*(.dynbss)
77	}
78
79	.dynstr : {
80		*(.dynstr)
81	}
82
83	.dynamic : {
84		*(.dynamic)
85	}
86
87	.plt : {
88		*(.plt)
89	}
90
91	.interp : {
92		*(.interp)
93	}
94
95	.gnu : {
96		*(.gnu*)
97	}
98
99	.MIPS.stubs : {
100		*(.MIPS.stubs)
101	}
102
103	.hash : {
104		*(.hash)
105	}
106}
107