File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1515
1616#include <asm/unistd.h>
1717
18+ .section .rodata
1819 .align 5
1920 .globl __kuser_helper_start
2021__kuser_helper_start:
Original file line number Diff line number Diff line change 1515
1616#include <asm/unistd.h>
1717
18+ . section .rodata
1819 .globl __aarch32_sigret_code_start
1920__aarch32_sigret_code_start:
2021
Original file line number Diff line number Diff line change @@ -24,7 +24,13 @@ btildflags-$(CONFIG_ARM64_BTI_KERNEL) += -z force-bti
2424# routines, as x86 does (see 6f121e548f83 ("x86, vdso: Reimplement vdso.so
2525# preparation in build-time C")).
2626ldflags-y := -shared -soname=linux-vdso.so.1 --hash-style=sysv \
27- -Bsymbolic --build-id=sha1 -n $(btildflags-y ) -T
27+ -Bsymbolic --build-id=sha1 -n $(btildflags-y )
28+
29+ ifdef CONFIG_LD_ORPHAN_WARN
30+ ldflags-y += --orphan-handling=warn
31+ endif
32+
33+ ldflags-y += -T
2834
2935ccflags-y := -fno-common -fno-builtin -fno-stack-protector -ffixed-x18
3036ccflags-y += -DDISABLE_BRANCH_PROFILING -DBUILD_VDSO
Original file line number Diff line number Diff line change 1111#include <linux/const.h>
1212#include <asm/page.h>
1313#include <asm/vdso.h>
14+ #include <asm-generic/vmlinux.lds.h>
1415
1516OUTPUT_FORMAT("elf64-littleaarch64" , "elf64-bigaarch64" , "elf64-littleaarch64" )
1617OUTPUT_ARCH(aarch64)
@@ -49,11 +50,24 @@ SECTIONS
4950
5051 .dynamic : { *(.dynamic) } :text :dynamic
5152
52- .rodata : { *(.rodata*) } :text
53+ .rela.dyn : ALIGN(8 ) { *(.rela .rela*) }
54+
55+ .rodata : {
56+ *(.rodata*)
57+ *(.got)
58+ *(.got.plt)
59+ *(.plt)
60+ *(.plt.*)
61+ *(.iplt)
62+ *(.igot .igot.plt)
63+ } :text
5364
5465 _end = .;
5566 PROVIDE(end = .);
5667
68+ DWARF_DEBUG
69+ ELF_DETAILS
70+
5771 /DISCARD/ : {
5872 *(.data .data .* .gnu.linkonce .d.* .sdata*)
5973 *(.bss .sbss .dynbss .dynsbss)
Original file line number Diff line number Diff line change @@ -104,6 +104,7 @@ VDSO_AFLAGS += -D__ASSEMBLY__
104104VDSO_LDFLAGS += -Bsymbolic --no-undefined -soname=linux-vdso.so.1
105105VDSO_LDFLAGS += -z max-page-size=4096 -z common-page-size=4096
106106VDSO_LDFLAGS += -shared --hash-style=sysv --build-id=sha1
107+ VDSO_LDFLAGS += --orphan-handling=warn
107108
108109
109110# Borrow vdsomunge.c from the arm vDSO
Original file line number Diff line number Diff line change 1111#include <linux/const.h>
1212#include <asm/page.h>
1313#include <asm/vdso.h>
14+ #include <asm-generic/vmlinux.lds.h>
1415
1516OUTPUT_FORMAT("elf32-littlearm" , "elf32-bigarm" , "elf32-littlearm" )
1617OUTPUT_ARCH(arm)
@@ -35,12 +36,30 @@ SECTIONS
3536
3637 .dynamic : { *(.dynamic) } :text :dynamic
3738
38- .rodata : { *(.rodata*) } :text
39+ .rodata : {
40+ *(.rodata*)
41+ *(.got)
42+ *(.got.plt)
43+ *(.plt)
44+ *(.rel.iplt)
45+ *(.iplt)
46+ *(.igot.plt)
47+ } :text
3948
40- .text : { *(.text *) } :text =0xe7f001f2
49+ .text : {
50+ *(.text *)
51+ *(.glue_7)
52+ *(.glue_7t)
53+ *(.vfp11_veneer)
54+ *(.v4_bx)
55+ } :text =0xe7f001f2
4156
42- .got : { *(.got) }
43- .rel.plt : { *(.rel.plt) }
57+ .rel.dyn : { *(.rel*) }
58+
59+ .ARM.exidx : { *(.ARM.exidx*) }
60+ DWARF_DEBUG
61+ ELF_DETAILS
62+ .ARM.attributes 0 : { *(.ARM.attributes) }
4463
4564 /DISCARD/ : {
4665 *(.note.GNU-stack)
You can’t perform that action at this time.
0 commit comments