Simon Glass | fc03fb9 | 2016-11-07 08:47:10 -0700 | [diff] [blame] | 1 | /* |
| 2 | * U-Boot ARM EFI linker script |
| 3 | * |
| 4 | * SPDX-License-Identifier: BSD-2-Clause |
| 5 | * |
| 6 | * Modified from elf_arm_efi.lds in gnu-efi |
| 7 | */ |
| 8 | |
| 9 | OUTPUT_FORMAT("elf32-littlearm", "elf32-littlearm", "elf32-littlearm") |
| 10 | OUTPUT_ARCH(arm) |
| 11 | ENTRY(_start) |
| 12 | SECTIONS |
| 13 | { |
| 14 | .text 0x0 : { |
| 15 | _text = .; |
| 16 | *(.text.head) |
| 17 | *(.text) |
| 18 | *(.text.*) |
| 19 | *(.gnu.linkonce.t.*) |
| 20 | *(.srodata) |
| 21 | *(.rodata*) |
| 22 | . = ALIGN(16); |
| 23 | } |
| 24 | _etext = .; |
| 25 | _text_size = . - _text; |
| 26 | .dynamic : { *(.dynamic) } |
| 27 | .data : { |
| 28 | _data = .; |
| 29 | *(.sdata) |
| 30 | *(.data) |
| 31 | *(.data1) |
| 32 | *(.data.*) |
| 33 | *(.got.plt) |
| 34 | *(.got) |
| 35 | |
| 36 | /* |
| 37 | * The EFI loader doesn't seem to like a .bss section, so we |
| 38 | * stick it all into .data: |
| 39 | */ |
| 40 | . = ALIGN(16); |
| 41 | _bss = .; |
| 42 | *(.sbss) |
| 43 | *(.scommon) |
| 44 | *(.dynbss) |
| 45 | *(.bss) |
| 46 | *(.bss.*) |
| 47 | *(COMMON) |
| 48 | . = ALIGN(16); |
| 49 | _bss_end = .; |
| 50 | _edata = .; |
| 51 | } |
| 52 | .rel.dyn : { *(.rel.dyn) } |
| 53 | .rel.plt : { *(.rel.plt) } |
| 54 | .rel.got : { *(.rel.got) } |
| 55 | .rel.data : { *(.rel.data) *(.rel.data*) } |
| 56 | _data_size = . - _etext; |
| 57 | |
Simon Glass | fc03fb9 | 2016-11-07 08:47:10 -0700 | [diff] [blame] | 58 | /DISCARD/ : { |
| 59 | *(.rel.reloc) |
| 60 | *(.eh_frame) |
| 61 | *(.note.GNU-stack) |
Alexander Graf | 71acd4f | 2017-12-11 09:45:30 +0100 | [diff] [blame] | 62 | *(.dynsym) |
| 63 | *(.dynstr) |
| 64 | *(.note.gnu.build-id) |
| 65 | *(.comment) |
Simon Glass | fc03fb9 | 2016-11-07 08:47:10 -0700 | [diff] [blame] | 66 | } |
Simon Glass | fc03fb9 | 2016-11-07 08:47:10 -0700 | [diff] [blame] | 67 | } |