1/*
2 * Copyright (c) 2020 Intel Corp.
3 *
4 * SPDX-License-Identifier: Apache-2.0
5 */
6
7
8ENTRY(efi_entry)
9
10SECTIONS {
11
12    /* Pick a reasonable base address, EFI won't load us there anyway */
13    . = 0x4000000;
14    .text : {
15        *(.text)
16        *(.rodata)
17    }
18
19    /* Must be a separately visible section to the EFI loader, doesn't
20     * need to be page-aligned and can be immediately after text/rodata */
21    .reloc :  { *(.reloc) }
22
23    /* Must be page-aligned or EFI balks */
24    . = ALIGN(4096);
25    .data : {
26        *(.data)
27        *(COMMON)
28        *(.bss)
29
30        *(.runtime_data_end) /* Must be last.  Obviously. */
31    }
32
33    /* Because binutils ld really likes to "helpfully" ignore the section
34     * directives and drop junk in weird places.
35     */
36    .trash_bin : {
37        *(.comment)
38        *(.data.rel*)
39        *(.dynamic)
40        *(.dynbss)
41        *(.dynstr)
42        *(.dynsym)
43        *(.eh_frame)
44        *(.gnu.hash)
45        *(.gnu.version*)
46        *(.got)
47        *(.got.plt)
48        *(.hash)
49        *(.note.*)
50        *(.plt)
51        *(.plt.*)
52        *(.rela.*)
53        *(.rel.local)
54    }
55
56} /* SECTIONS */
57