Skip to content

Commit 205f399

Browse files
jgoulywilldeacon
authored andcommitted
arm64: vdso: fix makefile dependency on vdso.so
There is currently no dependency for vdso*-wrap.S on vdso*.so, which means that you can get a build that uses a stale vdso*-wrap.o. In commit a5b8ca9, the file that includes the vdso.so was moved and renamed from arch/arm64/kernel/vdso/vdso.S to arch/arm64/kernel/vdso-wrap.S, when this happened the Makefile was not updated to force the dependcy on vdso.so. Fixes: a5b8ca9 ("arm64: do not descend to vdso directories twice") Signed-off-by: Joey Gouly <[email protected]> Cc: Masahiro Yamada <[email protected]> Cc: Vincenzo Frascino <[email protected]> Cc: Catalin Marinas <[email protected]> Cc: Will Deacon <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Will Deacon <[email protected]>
1 parent c35fe2a commit 205f399

File tree

3 files changed

+4
-6
lines changed

3 files changed

+4
-6
lines changed

arch/arm64/kernel/Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,10 @@ obj-$(CONFIG_ARM64_MTE) += mte.o
7575
obj-y += vdso-wrap.o
7676
obj-$(CONFIG_COMPAT_VDSO) += vdso32-wrap.o
7777

78+
# Force dependency (vdso*-wrap.S includes vdso.so through incbin)
79+
$(obj)/vdso-wrap.o: $(obj)/vdso/vdso.so
80+
$(obj)/vdso32-wrap.o: $(obj)/vdso32/vdso.so
81+
7882
obj-y += probes/
7983
head-y := head.o
8084
extra-y += $(head-y) vmlinux.lds

arch/arm64/kernel/vdso/Makefile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,6 @@ GCOV_PROFILE := n
5252
targets += vdso.lds
5353
CPPFLAGS_vdso.lds += -P -C -U$(ARCH)
5454

55-
# Force dependency (incbin is bad)
56-
$(obj)/vdso.o : $(obj)/vdso.so
57-
5855
# Link rule for the .so file, .lds has to be first
5956
$(obj)/vdso.so.dbg: $(obj)/vdso.lds $(obj-vdso) FORCE
6057
$(call if_changed,vdsold_and_vdso_check)

arch/arm64/kernel/vdso32/Makefile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -131,9 +131,6 @@ obj-vdso := $(c-obj-vdso) $(c-obj-vdso-gettimeofday) $(asm-obj-vdso)
131131
targets += vdso.lds
132132
CPPFLAGS_vdso.lds += -P -C -U$(ARCH)
133133

134-
# Force dependency (vdso.s includes vdso.so through incbin)
135-
$(obj)/vdso.o: $(obj)/vdso.so
136-
137134
include/generated/vdso32-offsets.h: $(obj)/vdso.so.dbg FORCE
138135
$(call if_changed,vdsosym)
139136

0 commit comments

Comments
 (0)