Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 1 | /* |
| 2 | * (C) Copyright 2002 |
| 3 | * Wolfgang Denk, DENX Software Engineering, wd@denx.de. |
| 4 | * |
Wolfgang Denk | 1a45966 | 2013-07-08 09:37:19 +0200 | [diff] [blame] | 5 | * SPDX-License-Identifier: GPL-2.0+ |
Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 6 | */ |
| 7 | |
| 8 | OUTPUT_ARCH(powerpc) |
Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 9 | /* Do we need any of these for elf? |
| 10 | __DYNAMIC = 0; */ |
| 11 | SECTIONS |
| 12 | { |
| 13 | .resetvec 0xF7FBFFFC : |
| 14 | { |
| 15 | *(.resetvec) |
| 16 | } = 0xffff |
| 17 | |
| 18 | .bootpg 0xF7FBF000 : |
| 19 | { |
Stefan Roese | a47a12b | 2010-04-15 16:07:28 +0200 | [diff] [blame] | 20 | arch/powerpc/cpu/ppc4xx/start.o (.bootpg) |
Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 21 | } = 0xffff |
| 22 | |
| 23 | /* Read-only sections, merged into text segment: */ |
| 24 | . = + SIZEOF_HEADERS; |
| 25 | .interp : { *(.interp) } |
| 26 | .hash : { *(.hash) } |
| 27 | .dynsym : { *(.dynsym) } |
| 28 | .dynstr : { *(.dynstr) } |
| 29 | .rel.text : { *(.rel.text) } |
Wolfgang Denk | 53677ef | 2008-05-20 16:00:29 +0200 | [diff] [blame] | 30 | .rela.text : { *(.rela.text) } |
Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 31 | .rel.data : { *(.rel.data) } |
Wolfgang Denk | 53677ef | 2008-05-20 16:00:29 +0200 | [diff] [blame] | 32 | .rela.data : { *(.rela.data) } |
| 33 | .rel.rodata : { *(.rel.rodata) } |
| 34 | .rela.rodata : { *(.rela.rodata) } |
Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 35 | .rel.got : { *(.rel.got) } |
| 36 | .rela.got : { *(.rela.got) } |
| 37 | .rel.ctors : { *(.rel.ctors) } |
| 38 | .rela.ctors : { *(.rela.ctors) } |
| 39 | .rel.dtors : { *(.rel.dtors) } |
| 40 | .rela.dtors : { *(.rela.dtors) } |
| 41 | .rel.bss : { *(.rel.bss) } |
| 42 | .rela.bss : { *(.rela.bss) } |
| 43 | .rel.plt : { *(.rel.plt) } |
| 44 | .rela.plt : { *(.rela.plt) } |
| 45 | .init : { *(.init) } |
| 46 | .plt : { *(.plt) } |
| 47 | .text : |
| 48 | { |
| 49 | /* WARNING - the following is hand-optimized to fit within */ |
| 50 | /* the sector layout of our flash chips! XXX FIXME XXX */ |
| 51 | |
Stefan Roese | a47a12b | 2010-04-15 16:07:28 +0200 | [diff] [blame] | 52 | arch/powerpc/cpu/ppc4xx/start.o (.text) |
Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 53 | |
| 54 | *(.text) |
Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 55 | *(.got1) |
| 56 | } |
| 57 | _etext = .; |
| 58 | PROVIDE (etext = .); |
| 59 | .rodata : |
| 60 | { |
Trent Piepho | f62fb99 | 2009-02-18 15:22:05 -0800 | [diff] [blame] | 61 | *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*))) |
Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 62 | } |
| 63 | .fini : { *(.fini) } =0 |
| 64 | .ctors : { *(.ctors) } |
| 65 | .dtors : { *(.dtors) } |
| 66 | |
| 67 | /* Read-write section, merged into data segment: */ |
| 68 | . = (. + 0x00FF) & 0xFFFFFF00; |
| 69 | _erotext = .; |
| 70 | PROVIDE (erotext = .); |
| 71 | .reloc : |
| 72 | { |
| 73 | *(.got) |
| 74 | _GOT2_TABLE_ = .; |
| 75 | *(.got2) |
| 76 | _FIXUP_TABLE_ = .; |
| 77 | *(.fixup) |
| 78 | } |
| 79 | __got2_entries = (_FIXUP_TABLE_ - _GOT2_TABLE_) >>2; |
| 80 | __fixup_entries = (. - _FIXUP_TABLE_)>>2; |
| 81 | |
| 82 | .data : |
| 83 | { |
| 84 | *(.data) |
| 85 | *(.data1) |
| 86 | *(.sdata) |
| 87 | *(.sdata2) |
| 88 | *(.dynamic) |
| 89 | CONSTRUCTORS |
| 90 | } |
| 91 | _edata = .; |
| 92 | PROVIDE (edata = .); |
| 93 | |
| 94 | . = .; |
Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 95 | |
Marek Vasut | 5567514 | 2012-10-12 10:27:03 +0000 | [diff] [blame] | 96 | .u_boot_list : { |
Albert ARIBAUD | ef123c5 | 2013-02-25 00:59:00 +0000 | [diff] [blame] | 97 | KEEP(*(SORT(.u_boot_list*))); |
Marek Vasut | 5567514 | 2012-10-12 10:27:03 +0000 | [diff] [blame] | 98 | } |
Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 99 | |
| 100 | . = .; |
| 101 | __start___ex_table = .; |
| 102 | __ex_table : { *(__ex_table) } |
| 103 | __stop___ex_table = .; |
| 104 | |
| 105 | . = ALIGN(256); |
| 106 | __init_begin = .; |
| 107 | .text.init : { *(.text.init) } |
| 108 | .data.init : { *(.data.init) } |
| 109 | . = ALIGN(256); |
| 110 | __init_end = .; |
| 111 | |
| 112 | __bss_start = .; |
| 113 | .bss (NOLOAD) : |
| 114 | { |
| 115 | *(.sbss) *(.scommon) |
| 116 | *(.dynbss) |
| 117 | *(.bss) |
| 118 | *(COMMON) |
Selvamuthukumar | 9b827cf | 2008-10-16 22:54:03 +0530 | [diff] [blame] | 119 | . = ALIGN(4); |
Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 120 | } |
| 121 | |
Simon Glass | 3929fb0 | 2013-03-14 06:54:53 +0000 | [diff] [blame] | 122 | __bss_end = . ; |
Larry Johnson | 6433fa2 | 2008-03-17 11:10:35 -0500 | [diff] [blame] | 123 | PROVIDE (end = .); |
| 124 | } |