Skip to contentSkip to conversation

kernel-devsrc: Add vdso.lds and other build files for riscv64 as well

PATCH New Khem Raj 1 participant 1 message Nov 3, 2021

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH 1/1 kernel-devsrc: Add vdso.lds and other build files for riscv64 as well

These additional bits are needed on riscv64 as well
Fixes
make[1]: *** No rule to make target 'arch/riscv/kernel/vdso/vdso.lds', needed by 'arch/riscv/kernel/vdso/vdso.so.dbg'. Stop.
make: *** [arch/riscv/Makefile:114: vdso_prepare] Error 2

Cc Bruce Ashfield <[email protected]>
---
 meta/recipes-kernel/linux/kernel-devsrc.bb | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)
meta/recipes-kernel/linux/kernel-devsrc.bb +8 -2
index d39573965f..f22fac5bd6 100644
@@ -109,8 +109,8 @@ do_install() {
 	    fi
 	fi
 
-	if [ "${ARCH}" = "arm64" ]; then
-	    cp -a --parents arch/arm64/kernel/vdso/vdso.lds $kerneldir/build/
+	if [ "${ARCH}" = "arm64" -o "${ARCH}" = "riscv" ]; then
+	    cp -a --parents arch/${ARCH}/kernel/vdso/vdso.lds $kerneldir/build/
 	fi
 	if [ "${ARCH}" = "powerpc" ]; then
 	    cp -a --parents arch/powerpc/kernel/vdso32/vdso32.lds $kerneldir/build 2>/dev/null || :
@@ -185,6 +185,12 @@ do_install() {
 	    cp -a --parents arch/${ARCH}/kernel/vdso32/* $kerneldir/build/ 2>/dev/null || :
 	    cp -a --parents arch/${ARCH}/kernel/vdso64/* $kerneldir/build/ 2>/dev/null || :
 	fi
+	if [ "${ARCH}" = "riscv" ]; then
+            cp -a --parents arch/riscv/kernel/vdso/*gettimeofday.* $kerneldir/build/
+            cp -a --parents arch/riscv/kernel/vdso/note.S $kerneldir/build/
+            cp -a --parents arch/riscv/kernel/vdso/gen_vdso_offsets.sh $kerneldir/build/
+	    cp -a --parents arch/riscv/kernel/vdso/* $kerneldir/build/ 2>/dev/null || :
+	fi
 
 	# include the machine specific headers for ARM variants, if available.
 	if [ "${ARCH}" = "arm" ]; then
Signature · 1 line
2.33.1