2013-01-30 04:31:52 +00:00
|
|
|
/*
|
|
|
|
* (C) Copyright 2003
|
|
|
|
* Wolfgang Denk Engineering, <wd@denx.de>
|
|
|
|
*
|
2013-07-08 07:37:19 +00:00
|
|
|
* SPDX-License-Identifier: GPL-2.0+
|
2013-01-30 04:31:52 +00:00
|
|
|
*/
|
|
|
|
|
|
|
|
#if defined(CONFIG_64BIT)
|
|
|
|
#define PTR_COUNT_SHIFT 3
|
|
|
|
#else
|
|
|
|
#define PTR_COUNT_SHIFT 2
|
|
|
|
#endif
|
|
|
|
|
|
|
|
OUTPUT_ARCH(mips)
|
|
|
|
ENTRY(_start)
|
|
|
|
SECTIONS
|
|
|
|
{
|
|
|
|
. = 0x00000000;
|
|
|
|
|
|
|
|
. = ALIGN(4);
|
|
|
|
.text : {
|
2016-09-21 10:11:06 +00:00
|
|
|
__text_start = .;
|
2013-01-30 04:31:52 +00:00
|
|
|
*(.text*)
|
2016-09-21 10:11:06 +00:00
|
|
|
__text_end = .;
|
2013-01-30 04:31:52 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
. = ALIGN(4);
|
|
|
|
.rodata : {
|
|
|
|
*(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
|
|
|
|
}
|
|
|
|
|
|
|
|
. = ALIGN(4);
|
|
|
|
.data : {
|
|
|
|
*(.data*)
|
|
|
|
}
|
|
|
|
|
|
|
|
. = .;
|
|
|
|
_gp = ALIGN(16) + 0x7ff0;
|
|
|
|
|
|
|
|
.got : {
|
|
|
|
*(.got)
|
|
|
|
}
|
|
|
|
|
2013-02-12 21:22:12 +00:00
|
|
|
num_got_entries = SIZEOF(.got) >> PTR_COUNT_SHIFT;
|
|
|
|
|
2013-01-30 04:31:52 +00:00
|
|
|
. = ALIGN(4);
|
|
|
|
.sdata : {
|
|
|
|
*(.sdata*)
|
|
|
|
}
|
|
|
|
|
|
|
|
. = ALIGN(4);
|
|
|
|
.u_boot_list : {
|
2013-02-25 00:59:00 +00:00
|
|
|
KEEP(*(SORT(.u_boot_list*)));
|
2013-01-30 04:31:52 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
. = ALIGN(4);
|
2013-02-12 21:22:12 +00:00
|
|
|
__image_copy_end = .;
|
2014-04-07 09:11:19 +00:00
|
|
|
__init_end = .;
|
2013-02-12 21:22:12 +00:00
|
|
|
|
2013-02-12 21:22:13 +00:00
|
|
|
.rel.dyn : {
|
|
|
|
__rel_dyn_start = .;
|
|
|
|
*(.rel.dyn)
|
|
|
|
__rel_dyn_end = .;
|
|
|
|
}
|
|
|
|
|
2014-10-29 16:30:36 +00:00
|
|
|
.padding : {
|
|
|
|
/*
|
|
|
|
* Workaround for a binutils feature (or bug?).
|
|
|
|
*
|
|
|
|
* The GNU ld from binutils puts the dynamic relocation
|
|
|
|
* entries into the .rel.dyn section. Sometimes it
|
|
|
|
* allocates more dynamic relocation entries than it needs
|
|
|
|
* and the unused slots are set to R_MIPS_NONE entries.
|
|
|
|
*
|
|
|
|
* However the size of the .rel.dyn section in the ELF
|
|
|
|
* section header does not cover the unused entries, so
|
|
|
|
* objcopy removes those during stripping.
|
|
|
|
*
|
|
|
|
* Create a small section here to avoid that.
|
|
|
|
*/
|
|
|
|
LONG(0xFFFFFFFF)
|
|
|
|
}
|
|
|
|
|
2013-10-11 15:46:59 +00:00
|
|
|
_end = .;
|
2013-02-12 21:22:13 +00:00
|
|
|
|
|
|
|
.bss __rel_dyn_start (OVERLAY) : {
|
2013-02-12 21:22:12 +00:00
|
|
|
__bss_start = .;
|
|
|
|
*(.sbss.*)
|
|
|
|
*(.bss.*)
|
|
|
|
*(COMMON)
|
2013-01-30 04:31:52 +00:00
|
|
|
. = ALIGN(4);
|
2013-02-12 21:22:12 +00:00
|
|
|
__bss_end = .;
|
2013-01-30 04:31:52 +00:00
|
|
|
}
|
2013-02-12 21:22:13 +00:00
|
|
|
|
2013-10-11 15:46:59 +00:00
|
|
|
.dynsym _end : {
|
|
|
|
*(.dynsym)
|
|
|
|
}
|
|
|
|
|
|
|
|
.dynbss : {
|
2013-02-12 21:22:13 +00:00
|
|
|
*(.dynbss)
|
2013-10-11 15:46:59 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.dynstr : {
|
2013-02-12 21:22:13 +00:00
|
|
|
*(.dynstr)
|
2013-10-11 15:46:59 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.dynamic : {
|
2013-02-12 21:22:13 +00:00
|
|
|
*(.dynamic)
|
2013-10-11 15:46:59 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.plt : {
|
|
|
|
*(.plt)
|
|
|
|
}
|
|
|
|
|
|
|
|
.interp : {
|
2013-02-12 21:22:13 +00:00
|
|
|
*(.interp)
|
2013-10-11 15:46:59 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.gnu : {
|
|
|
|
*(.gnu*)
|
|
|
|
}
|
|
|
|
|
|
|
|
.MIPS.stubs : {
|
|
|
|
*(.MIPS.stubs)
|
|
|
|
}
|
|
|
|
|
|
|
|
.hash : {
|
2013-02-12 21:22:13 +00:00
|
|
|
*(.hash)
|
|
|
|
}
|
2013-01-30 04:31:52 +00:00
|
|
|
}
|