blob: 5354172af0eb058bf5b307a6a63fe18c287c43d0 [file] [log] [blame]
Grant Likely17208ae2007-07-03 00:32:58 -06001/*
2 * (C) Copyright 2003-2004
3 * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
4 *
Wolfgang Denkd79de1d2013-07-08 09:37:19 +02005 * SPDX-License-Identifier: GPL-2.0+
Grant Likely17208ae2007-07-03 00:32:58 -06006 */
7
8OUTPUT_ARCH(powerpc)
Wolfgang Denk01fd9152010-11-23 13:20:22 +01009
Grant Likely17208ae2007-07-03 00:32:58 -060010SECTIONS
11{
12 /* Read-only sections, merged into text segment: */
Grant Likely17208ae2007-07-03 00:32:58 -060013 .text :
14 {
15 /* WARNING - the following is hand-optimized to fit within */
16 /* the sector layout of our flash chips! XXX FIXME XXX */
17
Wolfgang Denk01fd9152010-11-23 13:20:22 +010018 arch/powerpc/cpu/mpc5xxx/start.o (.text*)
19 arch/powerpc/cpu/mpc5xxx/traps.o (.text*)
Grant Likely17208ae2007-07-03 00:32:58 -060020
21 . = DEFINED(env_offset) ? env_offset : .;
Wolfgang Denk01fd9152010-11-23 13:20:22 +010022 common/env_embedded.o (.ppcenv*)
Grant Likely17208ae2007-07-03 00:32:58 -060023
Wolfgang Denk01fd9152010-11-23 13:20:22 +010024 *(.text*)
Grant Likely17208ae2007-07-03 00:32:58 -060025 . = ALIGN(16);
Trent Piepho4438e5e2009-02-18 15:22:05 -080026 *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
Grant Likely17208ae2007-07-03 00:32:58 -060027 }
Grant Likely17208ae2007-07-03 00:32:58 -060028
29 /* Read-write section, merged into data segment: */
30 . = (. + 0x0FFF) & 0xFFFFF000;
31 _erotext = .;
32 PROVIDE (erotext = .);
33 .reloc :
34 {
Wolfgang Denk01fd9152010-11-23 13:20:22 +010035 KEEP(*(.got))
Grant Likely17208ae2007-07-03 00:32:58 -060036 _GOT2_TABLE_ = .;
Wolfgang Denk01fd9152010-11-23 13:20:22 +010037 KEEP(*(.got2))
Grant Likely17208ae2007-07-03 00:32:58 -060038 _FIXUP_TABLE_ = .;
Wolfgang Denk01fd9152010-11-23 13:20:22 +010039 KEEP(*(.fixup))
Grant Likely17208ae2007-07-03 00:32:58 -060040 }
41 __got2_entries = (_FIXUP_TABLE_ - _GOT2_TABLE_) >> 2;
42 __fixup_entries = (. - _FIXUP_TABLE_) >> 2;
43
44 .data :
45 {
Wolfgang Denk01fd9152010-11-23 13:20:22 +010046 *(.data*)
47 *(.sdata*)
Grant Likely17208ae2007-07-03 00:32:58 -060048 }
49 _edata = .;
50 PROVIDE (edata = .);
51
52 . = .;
Grant Likely17208ae2007-07-03 00:32:58 -060053
Marek Vasut607092a2012-10-12 10:27:03 +000054 .u_boot_list : {
Albert ARIBAUDc24895e2013-02-25 00:59:00 +000055 KEEP(*(SORT(.u_boot_list*)));
Marek Vasut607092a2012-10-12 10:27:03 +000056 }
Grant Likely17208ae2007-07-03 00:32:58 -060057
58 . = .;
59 __start___ex_table = .;
60 __ex_table : { *(__ex_table) }
61 __stop___ex_table = .;
62
63 . = ALIGN(4096);
64 __init_begin = .;
65 .text.init : { *(.text.init) }
66 .data.init : { *(.data.init) }
67 . = ALIGN(4096);
68 __init_end = .;
69
70 __bss_start = .;
Wolfgang Denk828a9782008-01-12 20:31:39 +010071 .bss (NOLOAD) :
Grant Likely17208ae2007-07-03 00:32:58 -060072 {
Wolfgang Denk01fd9152010-11-23 13:20:22 +010073 *(.bss*)
74 *(.sbss*)
Grant Likely17208ae2007-07-03 00:32:58 -060075 *(COMMON)
Selvamuthukumard2454ba2008-10-16 22:54:03 +053076 . = ALIGN(4);
Grant Likely17208ae2007-07-03 00:32:58 -060077 }
Simon Glassed70c8f2013-03-14 06:54:53 +000078 __bss_end = . ;
Grant Likely17208ae2007-07-03 00:32:58 -060079 PROVIDE (end = .);
80}