hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/arch/s390/kernel/vmlinux.lds.S
....@@ -15,7 +15,12 @@
1515 /* Handle ro_after_init data on our own. */
1616 #define RO_AFTER_INIT_DATA
1717
18
+#define RUNTIME_DISCARD_EXIT
19
+
20
+#define EMITS_PT_NOTE
21
+
1822 #include <asm-generic/vmlinux.lds.h>
23
+#include <asm/vmlinux.lds.h>
1924
2025 OUTPUT_FORMAT("elf64-s390", "elf64-s390", "elf64-s390")
2126 OUTPUT_ARCH(s390:64-bit)
....@@ -49,11 +54,7 @@
4954 _etext = .; /* End of text section */
5055 } :text = 0x0700
5156
52
- NOTES :text :note
53
-
54
- .dummy : { *(.dummy) } :data
55
-
56
- RO_DATA_SECTION(PAGE_SIZE)
57
+ RO_DATA(PAGE_SIZE)
5758
5859 . = ALIGN(PAGE_SIZE);
5960 _sdata = .; /* Start of data section */
....@@ -62,12 +63,14 @@
6263 __start_ro_after_init = .;
6364 .data..ro_after_init : {
6465 *(.data..ro_after_init)
65
- }
66
+ JUMP_TABLE_DATA
67
+ } :data
6668 EXCEPTION_TABLE(16)
6769 . = ALIGN(PAGE_SIZE);
6870 __end_ro_after_init = .;
6971
70
- RW_DATA_SECTION(0x100, PAGE_SIZE, THREAD_SIZE)
72
+ RW_DATA(0x100, PAGE_SIZE, THREAD_SIZE)
73
+ BOOT_DATA_PRESERVED
7174
7275 _edata = .; /* End of data section */
7376
....@@ -121,6 +124,7 @@
121124 /*
122125 * Table with the patch locations to undo expolines
123126 */
127
+ . = ALIGN(4);
124128 .nospec_call_table : {
125129 __nospec_call_start = . ;
126130 *(.s390_indirect*)
....@@ -132,11 +136,25 @@
132136 __nospec_return_end = . ;
133137 }
134138
139
+ BOOT_DATA
140
+
135141 /* early.c uses stsi, which requires page aligned data. */
136142 . = ALIGN(PAGE_SIZE);
137143 INIT_DATA_SECTION(0x100)
138144
139145 PERCPU_SECTION(0x100)
146
+
147
+ .dynsym ALIGN(8) : {
148
+ __dynsym_start = .;
149
+ *(.dynsym)
150
+ __dynsym_end = .;
151
+ }
152
+ .rela.dyn ALIGN(8) : {
153
+ __rela_dyn_start = .;
154
+ *(.rela*)
155
+ __rela_dyn_end = .;
156
+ }
157
+
140158 . = ALIGN(PAGE_SIZE);
141159 __init_end = .; /* freed after init ends here */
142160
....@@ -144,13 +162,34 @@
144162
145163 _end = . ;
146164
165
+ /*
166
+ * uncompressed image info used by the decompressor
167
+ * it should match struct vmlinux_info
168
+ */
169
+ .vmlinux.info 0 (INFO) : {
170
+ QUAD(_stext) /* default_lma */
171
+ QUAD(startup_continue) /* entry */
172
+ QUAD(__bss_start - _stext) /* image_size */
173
+ QUAD(__bss_stop - __bss_start) /* bss_size */
174
+ QUAD(__boot_data_start) /* bootdata_off */
175
+ QUAD(__boot_data_end - __boot_data_start) /* bootdata_size */
176
+ QUAD(__boot_data_preserved_start) /* bootdata_preserved_off */
177
+ QUAD(__boot_data_preserved_end -
178
+ __boot_data_preserved_start) /* bootdata_preserved_size */
179
+ QUAD(__dynsym_start) /* dynsym_start */
180
+ QUAD(__rela_dyn_start) /* rela_dyn_start */
181
+ QUAD(__rela_dyn_end) /* rela_dyn_end */
182
+ } :NONE
183
+
147184 /* Debugging sections. */
148185 STABS_DEBUG
149186 DWARF_DEBUG
187
+ ELF_DETAILS
150188
151189 /* Sections to be discarded */
152190 DISCARDS
153191 /DISCARD/ : {
154192 *(.eh_frame)
193
+ *(.interp)
155194 }
156195 }