blob: fd0f1b5d4f444a2b75f701d63ee2bbf5c47fd68e [file] [log] [blame]
Tom Rini83d290c2018-05-06 17:58:06 -04001/* SPDX-License-Identifier: GPL-2.0+ */
Gabor Juhoscb5dbca2013-01-30 04:31:52 +00002/*
3 * (C) Copyright 2003
4 * Wolfgang Denk Engineering, <wd@denx.de>
Gabor Juhoscb5dbca2013-01-30 04:31:52 +00005 */
6
Gabor Juhoscb5dbca2013-01-30 04:31:52 +00007OUTPUT_ARCH(mips)
8ENTRY(_start)
9SECTIONS
10{
11 . = 0x00000000;
12
13 . = ALIGN(4);
14 .text : {
Paul Burtond263cda2016-09-21 11:11:06 +010015 __text_start = .;
Gabor Juhoscb5dbca2013-01-30 04:31:52 +000016 *(.text*)
Paul Burtond263cda2016-09-21 11:11:06 +010017 __text_end = .;
Gabor Juhoscb5dbca2013-01-30 04:31:52 +000018 }
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
Gabor Juhoscb5dbca2013-01-30 04:31:52 +000030 . = ALIGN(4);
31 .sdata : {
32 *(.sdata*)
33 }
34
35 . = ALIGN(4);
36 .u_boot_list : {
Albert ARIBAUDef123c52013-02-25 00:59:00 +000037 KEEP(*(SORT(.u_boot_list*)));
Gabor Juhoscb5dbca2013-01-30 04:31:52 +000038 }
39
Gabor Juhoscb5dbca2013-01-30 04:31:52 +000040 . = ALIGN(4);
Daniel Schwierzeck3420bf12013-02-12 22:22:12 +010041 __image_copy_end = .;
Paul Burtona0af08b2014-04-07 10:11:19 +010042 __init_end = .;
Daniel Schwierzeck3420bf12013-02-12 22:22:12 +010043
Daniel Schwierzeck96301462018-11-01 02:02:21 +010044 .data.reloc : {
Paul Burton703ec9d2017-06-19 11:53:47 -070045 __rel_start = .;
Daniel Schwierzeck96301462018-11-01 02:02:21 +010046 /*
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;
Daniel Schwierzeck265072b2014-10-29 17:30:36 +010057 }
58
Daniel Schwierzeck96301462018-11-01 02:02:21 +010059 . = ALIGN(4);
Daniel Schwierzeck79fd7e62013-10-11 17:46:59 +020060 _end = .;
Gabor Juhos0ba89262013-02-12 22:22:13 +010061
Paul Burton703ec9d2017-06-19 11:53:47 -070062 .bss __rel_start (OVERLAY) : {
Daniel Schwierzecka52852c2013-02-12 22:22:12 +010063 __bss_start = .;
64 *(.sbss.*)
65 *(.bss.*)
66 *(COMMON)
67 . = ALIGN(4);
68 __bss_end = .;
Gabor Juhoscb5dbca2013-01-30 04:31:52 +000069 }
Gabor Juhos0ba89262013-02-12 22:22:13 +010070
Daniel Schwierzeck79fd7e62013-10-11 17:46:59 +020071 .dynsym _end : {
72 *(.dynsym)
73 }
74
75 .dynbss : {
Gabor Juhos0ba89262013-02-12 22:22:13 +010076 *(.dynbss)
Daniel Schwierzeck79fd7e62013-10-11 17:46:59 +020077 }
78
79 .dynstr : {
Gabor Juhos0ba89262013-02-12 22:22:13 +010080 *(.dynstr)
Daniel Schwierzeck79fd7e62013-10-11 17:46:59 +020081 }
82
83 .dynamic : {
Gabor Juhos0ba89262013-02-12 22:22:13 +010084 *(.dynamic)
Daniel Schwierzeck79fd7e62013-10-11 17:46:59 +020085 }
86
87 .plt : {
Gabor Juhos0ba89262013-02-12 22:22:13 +010088 *(.plt)
Daniel Schwierzeck79fd7e62013-10-11 17:46:59 +020089 }
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)
Gabor Juhos0ba89262013-02-12 22:22:13 +0100105 }
Gabor Juhoscb5dbca2013-01-30 04:31:52 +0000106}