blob: df564e9395983837d590b0d5e321fda8469800d6 [file] [log] [blame]
wdenkdc7c9a12003-03-26 06:55:25 +00001/*
Wolfgang Denkcd0402a2010-11-20 15:07:45 +01002 * (C) Copyright 2000-2010
wdenkdc7c9a12003-03-26 06:55:25 +00003 * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
4 *
Wolfgang Denk1a459662013-07-08 09:37:19 +02005 * SPDX-License-Identifier: GPL-2.0+
wdenkdc7c9a12003-03-26 06:55:25 +00006 */
7
8OUTPUT_ARCH(powerpc)
Wolfgang Denkcd0402a2010-11-20 15:07:45 +01009
wdenkdc7c9a12003-03-26 06:55:25 +000010SECTIONS
11{
12 /* Read-only sections, merged into text segment: */
13 . = + SIZEOF_HEADERS;
wdenkdc7c9a12003-03-26 06:55:25 +000014 .text :
15 {
16 /* WARNING - the following is hand-optimized to fit within */
17 /* the sector layout of our flash chips! XXX FIXME XXX */
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010018 arch/powerpc/cpu/mpc8xx/start.o (.text*)
19 arch/powerpc/cpu/mpc8xx/traps.o (.text*)
Masahiro Yamadae2906a52013-11-11 14:36:00 +090020 lib/built-in.o (.text*)
21 net/built-in.o (.text*)
22 arch/powerpc/cpu/mpc8xx/built-in.o (.text*)
23 arch/powerpc/lib/built-in.o (.text*)
24 board/svm_sc8xx/built-in.o (.text*)
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010025 *(.text.*printf)
26 *(.text.do_mem_*)
27 *(.text.flash*)
28 *(.text.run_command)
29 *(.text.main_loop)
30 *(.text.srec_decode)
wdenkdc7c9a12003-03-26 06:55:25 +000031
32 . = env_offset;
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010033 common/env_embedded.o (.ppcenv*)
wdenkdc7c9a12003-03-26 06:55:25 +000034
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010035 *(.text*)
wdenkdc7c9a12003-03-26 06:55:25 +000036 }
37 _etext = .;
38 PROVIDE (etext = .);
39 .rodata :
40 {
Trent Piephof62fb992009-02-18 15:22:05 -080041 *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
wdenkdc7c9a12003-03-26 06:55:25 +000042 }
wdenkdc7c9a12003-03-26 06:55:25 +000043
44 /* Read-write section, merged into data segment: */
45 . = (. + 0x00FF) & 0xFFFFFF00;
46 _erotext = .;
47 PROVIDE (erotext = .);
48 .reloc :
49 {
wdenkdc7c9a12003-03-26 06:55:25 +000050 _GOT2_TABLE_ = .;
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010051 KEEP(*(.got2))
Joakim Tjernlund9d8fbd12011-04-20 14:22:59 +020052 KEEP(*(.got))
53 PROVIDE(_GLOBAL_OFFSET_TABLE_ = . + 4);
wdenkdc7c9a12003-03-26 06:55:25 +000054 _FIXUP_TABLE_ = .;
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010055 KEEP(*(.fixup))
wdenkdc7c9a12003-03-26 06:55:25 +000056 }
Joakim Tjernlund9d8fbd12011-04-20 14:22:59 +020057 __got2_entries = ((_GLOBAL_OFFSET_TABLE_ - _GOT2_TABLE_) >> 2) - 1;
wdenkdc7c9a12003-03-26 06:55:25 +000058 __fixup_entries = (. - _FIXUP_TABLE_)>>2;
59
60 .data :
61 {
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010062 *(.data*)
63 *(.sdata*)
wdenkdc7c9a12003-03-26 06:55:25 +000064 }
65 _edata = .;
66 PROVIDE (edata = .);
67
wdenk8bde7f72003-06-27 21:31:46 +000068
Wolfgang Denk807d5d72005-08-31 12:28:00 +020069 . = .;
wdenk8bde7f72003-06-27 21:31:46 +000070
Marek Vasut55675142012-10-12 10:27:03 +000071 . = ALIGN(4);
72 .u_boot_list : {
Albert ARIBAUDef123c52013-02-25 00:59:00 +000073 KEEP(*(SORT(.u_boot_list*)));
Marek Vasut55675142012-10-12 10:27:03 +000074 }
75
wdenk8bde7f72003-06-27 21:31:46 +000076
Wolfgang Denk807d5d72005-08-31 12:28:00 +020077 . = .;
wdenkdc7c9a12003-03-26 06:55:25 +000078 __start___ex_table = .;
79 __ex_table : { *(__ex_table) }
80 __stop___ex_table = .;
81
82 . = ALIGN(256);
83 __init_begin = .;
84 .text.init : { *(.text.init) }
85 .data.init : { *(.data.init) }
86 . = ALIGN(256);
87 __init_end = .;
88
89 __bss_start = .;
Wolfgang Denk64134f02008-01-12 20:31:39 +010090 .bss (NOLOAD) :
wdenkdc7c9a12003-03-26 06:55:25 +000091 {
Wolfgang Denkcd0402a2010-11-20 15:07:45 +010092 *(.bss*)
93 *(.sbss*)
wdenkdc7c9a12003-03-26 06:55:25 +000094 *(COMMON)
Selvamuthukumar9b827cf2008-10-16 22:54:03 +053095 . = ALIGN(4);
wdenkdc7c9a12003-03-26 06:55:25 +000096 }
Simon Glass3929fb02013-03-14 06:54:53 +000097 __bss_end = . ;
wdenkdc7c9a12003-03-26 06:55:25 +000098 PROVIDE (end = .);
99}