blob: 667dc54e173805cfc4109fc338d356386d954d76 [file] [log] [blame]
wdenk3bbc8992003-12-07 22:27:15 +00001/*
Wolfgang Denkcd0402a2010-11-20 15:07:45 +01002 * (C) Copyright 2000-2010
wdenk3bbc8992003-12-07 22:27:15 +00003 * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
4 *
Wolfgang Denk1a459662013-07-08 09:37:19 +02005 * SPDX-License-Identifier: GPL-2.0+
wdenk3bbc8992003-12-07 22:27:15 +00006 */
7
8OUTPUT_ARCH(powerpc)
Wolfgang Denkcd0402a2010-11-20 15:07:45 +01009
wdenk3bbc8992003-12-07 22:27:15 +000010SECTIONS
11{
12 /* Read-only sections, merged into text segment: */
13 . = + SIZEOF_HEADERS;
wdenk3bbc8992003-12-07 22:27:15 +000014 .text :
15 {
16 /* WARNING - the following is hand-optimized to fit within */
17 /* the sector layout of our flash chips! XXX FIXME XXX */
18
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010019 arch/powerpc/cpu/mpc8xx/start.o (.text*)
20 arch/powerpc/cpu/mpc8xx/traps.o (.text*)
wdenk3bbc8992003-12-07 22:27:15 +000021
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010022 *(.text*)
wdenk3bbc8992003-12-07 22:27:15 +000023 }
24 _etext = .;
25 PROVIDE (etext = .);
26 .rodata :
27 {
Trent Piephof62fb992009-02-18 15:22:05 -080028 *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
wdenk3bbc8992003-12-07 22:27:15 +000029 }
wdenk3bbc8992003-12-07 22:27:15 +000030
31 /* Read-write section, merged into data segment: */
32 . = (. + 0x00FF) & 0xFFFFFF00;
33 _erotext = .;
34 PROVIDE (erotext = .);
35 .reloc :
36 {
wdenk3bbc8992003-12-07 22:27:15 +000037 _GOT2_TABLE_ = .;
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010038 KEEP(*(.got2))
Joakim Tjernlund9d8fbd12011-04-20 14:22:59 +020039 KEEP(*(.got))
40 PROVIDE(_GLOBAL_OFFSET_TABLE_ = . + 4);
wdenk3bbc8992003-12-07 22:27:15 +000041 _FIXUP_TABLE_ = .;
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010042 KEEP(*(.fixup))
wdenk3bbc8992003-12-07 22:27:15 +000043 }
Joakim Tjernlund9d8fbd12011-04-20 14:22:59 +020044 __got2_entries = ((_GLOBAL_OFFSET_TABLE_ - _GOT2_TABLE_) >> 2) - 1;
wdenk3bbc8992003-12-07 22:27:15 +000045 __fixup_entries = (. - _FIXUP_TABLE_)>>2;
46
47 .data :
48 {
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010049 *(.data*)
50 *(.sdata*)
wdenk3bbc8992003-12-07 22:27:15 +000051 }
52 _edata = .;
53 PROVIDE (edata = .);
54
Wolfgang Denk807d5d72005-08-31 12:28:00 +020055 . = .;
wdenk3bbc8992003-12-07 22:27:15 +000056
Marek Vasut55675142012-10-12 10:27:03 +000057 . = ALIGN(4);
58 .u_boot_list : {
Albert ARIBAUDef123c52013-02-25 00:59:00 +000059 KEEP(*(SORT(.u_boot_list*)));
Marek Vasut55675142012-10-12 10:27:03 +000060 }
61
wdenk3bbc8992003-12-07 22:27:15 +000062
Wolfgang Denk807d5d72005-08-31 12:28:00 +020063 . = .;
wdenk3bbc8992003-12-07 22:27:15 +000064 __start___ex_table = .;
65 __ex_table : { *(__ex_table) }
66 __stop___ex_table = .;
67
68 . = ALIGN(256);
69 __init_begin = .;
70 .text.init : { *(.text.init) }
71 .data.init : { *(.data.init) }
72 . = ALIGN(256);
73 __init_end = .;
74
75 __bss_start = .;
Wolfgang Denk64134f02008-01-12 20:31:39 +010076 .bss (NOLOAD) :
wdenk3bbc8992003-12-07 22:27:15 +000077 {
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010078 *(.bss*)
79 *(.sbss*)
wdenk3bbc8992003-12-07 22:27:15 +000080 *(COMMON)
Selvamuthukumar9b827cf2008-10-16 22:54:03 +053081 . = ALIGN(4);
wdenk3bbc8992003-12-07 22:27:15 +000082 }
Simon Glass3929fb02013-03-14 06:54:53 +000083 __bss_end = . ;
wdenk3bbc8992003-12-07 22:27:15 +000084 PROVIDE (end = .);
85}