blob: 4c63ff2946f7f9324a06f91fba1f9543561726fd [file] [log] [blame]
wdenk4a5b6a32001-04-28 17:59:11 +00001/*
Wolfgang Denke71d99d2010-11-20 15:07:45 +01002 * (C) Copyright 2000-2010
wdenk4a5b6a32001-04-28 17:59:11 +00003 * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
4 *
Wolfgang Denkd79de1d2013-07-08 09:37:19 +02005 * SPDX-License-Identifier: GPL-2.0+
wdenk4a5b6a32001-04-28 17:59:11 +00006 */
7
Wolfgang Denkff8faa42010-11-24 19:19:08 +01008#include <config.h>
wdenk4a5b6a32001-04-28 17:59:11 +00009OUTPUT_ARCH(powerpc)
Wolfgang Denke71d99d2010-11-20 15:07:45 +010010
wdenk4a5b6a32001-04-28 17:59:11 +000011SECTIONS
12{
13 /* Read-only sections, merged into text segment: */
14 . = + SIZEOF_HEADERS;
wdenk4a5b6a32001-04-28 17:59:11 +000015 .text :
16 {
Wolfgang Denkff8faa42010-11-24 19:19:08 +010017#ifdef CONFIG_MPC8260
18 arch/powerpc/cpu/mpc8260/start.o (.text*)
19#else
Wolfgang Denke71d99d2010-11-20 15:07:45 +010020 arch/powerpc/cpu/mpc8xx/start.o (.text*)
21 arch/powerpc/cpu/mpc8xx/traps.o (.text*)
Wolfgang Denkff8faa42010-11-24 19:19:08 +010022#endif
Wolfgang Denke71d99d2010-11-20 15:07:45 +010023 *(.text*)
wdenk4a5b6a32001-04-28 17:59:11 +000024 }
25 _etext = .;
26 PROVIDE (etext = .);
27 .rodata :
28 {
Trent Piepho4438e5e2009-02-18 15:22:05 -080029 *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
wdenk4a5b6a32001-04-28 17:59:11 +000030 }
wdenk4a5b6a32001-04-28 17:59:11 +000031
32 /* Read-write section, merged into data segment: */
33 . = (. + 0x0FFF) & 0xFFFFF000;
34 _erotext = .;
35 PROVIDE (erotext = .);
36 .reloc :
37 {
wdenk4a5b6a32001-04-28 17:59:11 +000038 _GOT2_TABLE_ = .;
Wolfgang Denke71d99d2010-11-20 15:07:45 +010039 KEEP(*(.got2))
Joakim Tjernlunda65f8c82011-04-20 14:22:59 +020040 KEEP(*(.got))
41 PROVIDE(_GLOBAL_OFFSET_TABLE_ = . + 4);
wdenk4a5b6a32001-04-28 17:59:11 +000042 _FIXUP_TABLE_ = .;
Wolfgang Denke71d99d2010-11-20 15:07:45 +010043 KEEP(*(.fixup))
wdenk4a5b6a32001-04-28 17:59:11 +000044 }
Joakim Tjernlunda65f8c82011-04-20 14:22:59 +020045 __got2_entries = ((_GLOBAL_OFFSET_TABLE_ - _GOT2_TABLE_) >> 2) - 1;
wdenk4a5b6a32001-04-28 17:59:11 +000046 __fixup_entries = (. - _FIXUP_TABLE_)>>2;
47
48 .data :
49 {
Wolfgang Denke71d99d2010-11-20 15:07:45 +010050 *(.data*)
51 *(.sdata*)
wdenk4a5b6a32001-04-28 17:59:11 +000052 }
53 _edata = .;
54 PROVIDE (edata = .);
55
Wolfgang Denk5dd2c652005-08-31 12:28:00 +020056 . = .;
wdenk57b2d802003-06-27 21:31:46 +000057
Marek Vasut607092a2012-10-12 10:27:03 +000058 . = ALIGN(4);
59 .u_boot_list : {
Albert ARIBAUDc24895e2013-02-25 00:59:00 +000060 KEEP(*(SORT(.u_boot_list*)));
Marek Vasut607092a2012-10-12 10:27:03 +000061 }
62
wdenk57b2d802003-06-27 21:31:46 +000063
Wolfgang Denk5dd2c652005-08-31 12:28:00 +020064 . = .;
wdenk4a5b6a32001-04-28 17:59:11 +000065 __start___ex_table = .;
66 __ex_table : { *(__ex_table) }
67 __stop___ex_table = .;
68
69 . = ALIGN(4096);
70 __init_begin = .;
71 .text.init : { *(.text.init) }
72 .data.init : { *(.data.init) }
73 . = ALIGN(4096);
74 __init_end = .;
75
76 __bss_start = .;
Wolfgang Denk828a9782008-01-12 20:31:39 +010077 .bss (NOLOAD) :
wdenk4a5b6a32001-04-28 17:59:11 +000078 {
Wolfgang Denke71d99d2010-11-20 15:07:45 +010079 *(.bss*)
80 *(.sbss*)
wdenk4a5b6a32001-04-28 17:59:11 +000081 *(COMMON)
Selvamuthukumard2454ba2008-10-16 22:54:03 +053082 . = ALIGN(4);
wdenk4a5b6a32001-04-28 17:59:11 +000083 }
Simon Glassed70c8f2013-03-14 06:54:53 +000084 __bss_end = . ;
wdenk4a5b6a32001-04-28 17:59:11 +000085 PROVIDE (end = .);
86}