blob: 463af7eaa4c57b7731a9cd2cd79b4e48d1a3ef3b [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
8OUTPUT_ARCH(powerpc)
Wolfgang Denke71d99d2010-11-20 15:07:45 +01009
wdenk4a5b6a32001-04-28 17:59:11 +000010SECTIONS
11{
12 /* Read-only sections, merged into text segment: */
13 . = + SIZEOF_HEADERS;
wdenk4a5b6a32001-04-28 17:59:11 +000014 .text :
15 {
Wolfgang Denke71d99d2010-11-20 15:07:45 +010016 /* WARNING - the following is hand-optimized to fit within */
17 /* the sector layout of our flash chips! XXX FIXME XXX */
18
19 arch/powerpc/cpu/mpc8xx/start.o (.text*)
20 arch/powerpc/cpu/mpc8xx/traps.o (.text*)
Masahiro Yamada30a198b2013-11-11 14:36:00 +090021 net/built-in.o (.text*)
22 arch/powerpc/cpu/mpc8xx/built-in.o (.text*)
Wolfgang Denke71d99d2010-11-20 15:07:45 +010023 *(.text.v*printf)
24
25 . = DEFINED(env_offset) ? env_offset : .;
26 common/env_embedded.o (.ppcenv*)
27
28 *(.text*)
wdenk4a5b6a32001-04-28 17:59:11 +000029 }
30 _etext = .;
31 PROVIDE (etext = .);
32 .rodata :
33 {
Trent Piepho4438e5e2009-02-18 15:22:05 -080034 *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
wdenk4a5b6a32001-04-28 17:59:11 +000035 }
wdenk4a5b6a32001-04-28 17:59:11 +000036
37 /* Read-write section, merged into data segment: */
38 . = (. + 0x0FF) & 0xFFFFFF00;
39 _erotext = .;
40 PROVIDE (erotext = .);
41 .reloc :
42 {
wdenk4a5b6a32001-04-28 17:59:11 +000043 _GOT2_TABLE_ = .;
Wolfgang Denke71d99d2010-11-20 15:07:45 +010044 KEEP(*(.got2))
Joakim Tjernlunda65f8c82011-04-20 14:22:59 +020045 KEEP(*(.got))
46 PROVIDE(_GLOBAL_OFFSET_TABLE_ = . + 4);
wdenk4a5b6a32001-04-28 17:59:11 +000047 _FIXUP_TABLE_ = .;
Wolfgang Denke71d99d2010-11-20 15:07:45 +010048 KEEP(*(.fixup))
wdenk4a5b6a32001-04-28 17:59:11 +000049 }
Joakim Tjernlunda65f8c82011-04-20 14:22:59 +020050 __got2_entries = ((_GLOBAL_OFFSET_TABLE_ - _GOT2_TABLE_) >> 2) - 1;
wdenk4a5b6a32001-04-28 17:59:11 +000051 __fixup_entries = (. - _FIXUP_TABLE_)>>2;
52
53 .data :
54 {
Wolfgang Denke71d99d2010-11-20 15:07:45 +010055 *(.data*)
56 *(.sdata*)
wdenk4a5b6a32001-04-28 17:59:11 +000057 }
58 _edata = .;
59 PROVIDE (edata = .);
60
Wolfgang Denk5dd2c652005-08-31 12:28:00 +020061 . = .;
wdenk57b2d802003-06-27 21:31:46 +000062
Marek Vasut607092a2012-10-12 10:27:03 +000063 . = ALIGN(4);
64 .u_boot_list : {
Albert ARIBAUDc24895e2013-02-25 00:59:00 +000065 KEEP(*(SORT(.u_boot_list*)));
Marek Vasut607092a2012-10-12 10:27:03 +000066 }
67
wdenk57b2d802003-06-27 21:31:46 +000068
Wolfgang Denk5dd2c652005-08-31 12:28:00 +020069 . = .;
wdenk4a5b6a32001-04-28 17:59:11 +000070 __start___ex_table = .;
71 __ex_table : { *(__ex_table) }
72 __stop___ex_table = .;
73
74 . = ALIGN(256);
75 __init_begin = .;
76 .text.init : { *(.text.init) }
77 .data.init : { *(.data.init) }
78 . = ALIGN(256);
79 __init_end = .;
80
81 __bss_start = .;
Wolfgang Denk828a9782008-01-12 20:31:39 +010082 .bss (NOLOAD) :
wdenk4a5b6a32001-04-28 17:59:11 +000083 {
Wolfgang Denke71d99d2010-11-20 15:07:45 +010084 *(.bss*)
85 *(.sbss*)
wdenk4a5b6a32001-04-28 17:59:11 +000086 *(COMMON)
Selvamuthukumard2454ba2008-10-16 22:54:03 +053087 . = ALIGN(4);
wdenk4a5b6a32001-04-28 17:59:11 +000088 }
Simon Glassed70c8f2013-03-14 06:54:53 +000089 __bss_end = . ;
wdenk4a5b6a32001-04-28 17:59:11 +000090 PROVIDE (end = .);
91}