1 /* SPDX-License-Identifier: GPL-2.0 */
3 #ifdef CONFIG_HOTPLUG_CPU
4 #define ARM_CPU_DISCARD(x)
5 #define ARM_CPU_KEEP(x) x
7 #define ARM_CPU_DISCARD(x) x
8 #define ARM_CPU_KEEP(x)
11 #if (defined(CONFIG_SMP_ON_UP) && !defined(CONFIG_DEBUG_SPINLOCK)) || \
12 defined(CONFIG_GENERIC_BUG) || defined(CONFIG_JUMP_LABEL)
13 #define ARM_EXIT_KEEP(x) x
14 #define ARM_EXIT_DISCARD(x)
16 #define ARM_EXIT_KEEP(x)
17 #define ARM_EXIT_DISCARD(x) x
21 #define ARM_MMU_KEEP(x) x
22 #define ARM_MMU_DISCARD(x)
24 #define ARM_MMU_KEEP(x)
25 #define ARM_MMU_DISCARD(x) x
30 __proc_info_begin = .; \
34 #define HYPERVISOR_TEXT \
35 __hyp_text_start = .; \
41 __idmap_text_start = .; \
43 __idmap_text_end = .; \
44 . = ALIGN(PAGE_SIZE); \
45 __hyp_idmap_text_start = .; \
47 __hyp_idmap_text_end = .;
50 *(.ARM.exidx.exit.text) \
51 *(.ARM.extab.exit.text) \
52 *(.ARM.exidx.text.exit) \
53 *(.ARM.extab.text.exit) \
54 ARM_CPU_DISCARD(*(.ARM.exidx.cpuexit.text)) \
55 ARM_CPU_DISCARD(*(.ARM.extab.cpuexit.text)) \
56 ARM_EXIT_DISCARD(EXIT_TEXT) \
57 ARM_EXIT_DISCARD(EXIT_DATA) \
59 ARM_MMU_DISCARD(*(.text.fixup)) \
60 ARM_MMU_DISCARD(*(__ex_table)) \
66 __entry_text_start = .; \
68 __entry_text_end = .; \
81 *(.got) /* Global offset table */ \
82 ARM_CPU_KEEP(PROC_INFO)
84 /* Stack unwinding tables */
85 #define ARM_UNWIND_SECTIONS \
88 __start_unwind_idx = .; \
90 __stop_unwind_idx = .; \
93 __start_unwind_tab = .; \
95 __stop_unwind_tab = .; \
99 * The vectors and stubs are relocatable code, and the
100 * only thing that matters is their relative offsets
102 #define ARM_VECTORS \
103 __vectors_start = .; \
104 .vectors 0xffff0000 : AT(__vectors_start) { \
107 . = __vectors_start + SIZEOF(.vectors); \
111 .stubs ADDR(.vectors) + 0x1000 : AT(__stubs_start) { \
114 . = __stubs_start + SIZEOF(.stubs); \
117 PROVIDE(vector_fiq_offset = vector_fiq - ADDR(.vectors));
120 __itcm_start = ALIGN(4); \
121 .text_itcm ITCM_OFFSET : AT(__itcm_start - LOAD_OFFSET) { \
128 . = __itcm_start + SIZEOF(.text_itcm); \
131 .data_dtcm DTCM_OFFSET : AT(__dtcm_start - LOAD_OFFSET) { \
137 . = __dtcm_start + SIZEOF(.data_dtcm);