1 /* SPDX-License-Identifier: GPL-2.0+ */
4 * David Feng <fenghua@phytium.com.cn>
7 * Gary Jennejohn, DENX Software Engineering, <garyj@denx.de>
13 OUTPUT_FORMAT("elf64-littleaarch64", "elf64-littleaarch64", "elf64-littleaarch64")
18 #ifdef CONFIG_ARMV8_SECURE_BASE
19 /DISCARD/ : { *(.rela._secure*) }
26 *(.__image_copy_start)
27 CPUDIR/start.o (.text*)
31 #ifdef CONFIG_ARMV8_PSCI
33 #ifndef CONFIG_ARMV8_SECURE_BASE
34 ALIGN(CONSTANT(COMMONPAGESIZE))
37 KEEP(*(.__secure_start))
40 #ifndef CONFIG_ARMV8_SECURE_BASE
41 #define CONFIG_ARMV8_SECURE_BASE
42 #define __ARMV8_PSCI_STACK_IN_RAM
44 .secure_text CONFIG_ARMV8_SECURE_BASE :
45 AT(ADDR(.__secure_start) + SIZEOF(.__secure_start))
50 .secure_data : AT(LOADADDR(.secure_text) + SIZEOF(.secure_text))
55 .secure_stack ALIGN(ADDR(.secure_data) + SIZEOF(.secure_data),
56 CONSTANT(COMMONPAGESIZE)) (NOLOAD) :
57 #ifdef __ARMV8_PSCI_STACK_IN_RAM
58 AT(ADDR(.secure_stack))
60 AT(LOADADDR(.secure_data) + SIZEOF(.secure_data))
63 KEEP(*(.__secure_stack_start))
65 . = . + CONFIG_ARMV8_PSCI_NR_CPUS * ARM_PSCI_STACK_SIZE;
67 . = ALIGN(CONSTANT(COMMONPAGESIZE));
69 KEEP(*(.__secure_stack_end))
72 #ifndef __ARMV8_PSCI_STACK_IN_RAM
73 . = LOADADDR(.secure_stack);
76 .__secure_end : AT(ADDR(.__secure_end)) {
77 KEEP(*(.__secure_end))
78 LONG(0x1d1071c); /* Must output something to reset LMA */
83 .rodata : { *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*))) }
96 KEEP(*(SORT(.u_boot_list*)));
102 __efi_runtime_start = .;
105 __efi_runtime_stop = .;
109 __efi_runtime_rel_start = .;
110 *(.relaefi_runtime_text)
111 *(.relaefi_runtime_data)
112 __efi_runtime_rel_stop = .;
143 KEEP(*(.__bss_start));
155 /DISCARD/ : { *(.dynsym) }
156 /DISCARD/ : { *(.dynstr*) }
157 /DISCARD/ : { *(.dynamic*) }
158 /DISCARD/ : { *(.plt*) }
159 /DISCARD/ : { *(.interp*) }
160 /DISCARD/ : { *(.gnu*) }
162 #ifdef CONFIG_LINUX_KERNEL_IMAGE_HEADER
163 #include "linux-kernel-image-header-vars.h"