From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=193.142.43.55 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796369451; b=enktkWyCFuel5ZOOJPzNfiQKiLBjVUhwJOMeEmtCy0/c6D+3j7IGQrQl/Ew2xZH8TxDM SB2Iph5XV/r1DeP+Pl1qXBmE3Qx4UExJn8qECP/0JwjtJ9ftvCRRJfmeqUH0zWpXBjHzK Q4U1LVrC1ESH6Wqgw1OyuqJCpcU+Yw6wn0exDXBxWR1UPTKHr09M73kNY4uQRs8cNNy3u EzKG3q7uwejgSvI+Pkr0uXm9/ZahKtCJ5PbVOw6MIszWteKZzUQEN/4yuDpjNhwkU/bh0 ZNVcHpa98Lsi3kjHEHmSHN139BXaHCIZpRuneoAmg50RLxPS/o5h3wcC6lYB9gyYRwg== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796369451; h=DMARC-Filter:From:DKIM-Signature:DKIM-Signature:Date:Subject: MIME-Version:Content-Type:Content-Transfer-Encoding:Message-Id: References:In-Reply-To:To:Cc:X-Developer-Signature:X-Developer-Key; bh=L0aGZ4Fso3870MXqX0Efn+lHPPoTGBz8PKP3XNBU+WQ=; b=UUc/vytuv6IIkPiWFYHxIAwbG+JNdxC1vAtTbWYuccgjv33umhOqCVTfINSK8EFYKPYQ 5PMj1uQ/gFEPVM0+EH3e/bHVknVnRGaCs09FuNuS9rmqoyvEI7CYhVbFvK/qDEaIlH58w LCu8ubiffClFBDvd01J4hgXVeD5nRvs8RfBdDKDWmHYFIT2VX7nvoJhEeyfDmPC1jMcGg 3w0F4iTxxDnbR2M617NwtwE+cACaEGmaeAG7GYQYO/fpDSjlf0TeFxH0WtiMo7bj4FZnt HjecRiwNPp9BoXvN+fXSkZn/3JbX/k+1tppgBWj9yHu5ZW/u0nKhpWndfANvvMIT5Yw== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass header.d=linutronix.de header.i=@linutronix.de header.a=rsa-sha256 header.s=2020 header.b=lNZmLmkB; dkim=pass header.d=linutronix.de header.i=@linutronix.de header.a=ed25519-sha256 header.s=2020e header.b=sdJNLDsD; arc=none smtp.remote-ip=193.142.43.55 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B38F6606A33D; Fri, 4 Dec 2026 07:30:50 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org B38F6606A33D Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linutronix.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.a=rsa-sha256 header.s=2020 header.b=lNZmLmkB; dkim=pass header.d=linutronix.de header.i=@linutronix.de header.a=ed25519-sha256 header.s=2020e header.b=sdJNLDsD From: =?utf-8?q?Thomas_Wei=C3=9Fschuh?= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1796369449; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=L0aGZ4Fso3870MXqX0Efn+lHPPoTGBz8PKP3XNBU+WQ=; b=lNZmLmkB9nSxbZNeFrYHKQG4lD7GX0cSzdou+shIcwCx9N9jn6LncSiSnWunbt3oJRfLDw G5k8bDkL0Gsa6Ss+Qe8hvgGpzYKmxao/LX6lnQiLxqqjTl0khhGhdwRcvRfLEdPIBjRktC ZysADIOLL7eKCpJH1YhG00GlHBf/YGssSbd5Awn8fXcQrZ0yaOuE72CoKxqDiQUGQ6CR0O kCZpAfPxC+tdhOvzy3XKel968pJLxsRC7K+9Tk08Jivr/ypUTraL6MtXnUGLHrqlwcFir5 7Hsy3K4SNc5DNTVADErUkw2Zcs+DieacRHeFqbCXlmTKB4I50euGz5o7JnaY9w== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1796369449; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=L0aGZ4Fso3870MXqX0Efn+lHPPoTGBz8PKP3XNBU+WQ=; b=sdJNLDsDB2neCBenccDIhQ9XYGxaryhqBoS8SfM1YELa5L8aaA+lDozYWdqOXLGvaqwm+p WqPTKAgg9d/OJgCg== Date: Fri, 04 Dec 2026 08:30:29 +0100 Subject: [PATCH 2/9] arm64/vdso: Directly include the generic vDSO implementations X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Message-Id: <20261204-vdso-generic-include-v1-2-8f4ed31bfbbd@linutronix.de> References: <20261204-vdso-generic-include-v1-0-8f4ed31bfbbd@linutronix.de> In-Reply-To: <20261204-vdso-generic-include-v1-0-8f4ed31bfbbd@linutronix.de> To: Thomas Gleixner , Andy Lutomirski , Vincenzo Frascino Cc: linux-csky@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, loongarch@lists.linux.dev, linuxppc-dev@lists.ozlabs.org, linux-mips@vger.kernel.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, =?utf-8?q?Thomas_Wei=C3=9Fschuh?= X-Developer-Signature: v=1; a=ed25519-sha256; t=1796369447; l=3195; i=thomas.weissschuh@linutronix.de; s=20240209; h=from:subject:message-id; bh=TmZxgfp85eUyCPXrgd/WTq83PKEDLMiFmJdPM41y5Fw=; b=ZRXgacTK48Te7Fjyj5UzpuRd7X6ZqUOXa3Cs0Z8BVFFkQeZYk1gceL1OQR3gboBOpALIfA8kr TvSkPPnlZ93BZJblQNtKDD1h3sbfg+PpMEaB0DcGZmuOLTBKSubwnOa X-Developer-Key: i=thomas.weissschuh@linutronix.de; a=ed25519; pk=pfvxvpFUDJV2h2nY0FidLUml22uGLSjByFbM6aqQQws= The inclusion of the generic vDSO implementation through compiler arguments is complicated and non-obvious. Directly include the .c files instead. Signed-off-by: Thomas Weißschuh --- arch/arm64/kernel/vdso/Makefile | 8 -------- arch/arm64/kernel/vdso/vgetrandom.c | 2 ++ arch/arm64/kernel/vdso/vgettimeofday.c | 2 ++ arch/arm64/kernel/vdso32/Makefile | 4 ---- arch/arm64/kernel/vdso32/vgettimeofday.c | 2 ++ 5 files changed, 6 insertions(+), 12 deletions(-) diff --git a/arch/arm64/kernel/vdso/Makefile b/arch/arm64/kernel/vdso/Makefile index f6619e1cb2ce..b119f08a14da 100644 --- a/arch/arm64/kernel/vdso/Makefile +++ b/arch/arm64/kernel/vdso/Makefile @@ -49,14 +49,6 @@ CFLAGS_REMOVE_vgetrandom.o = $(CC_FLAGS_REMOVE_VDSO) CFLAGS_vgettimeofday.o = $(CC_FLAGS_ADD_VDSO) CFLAGS_vgetrandom.o = $(CC_FLAGS_ADD_VDSO) -ifneq ($(c-gettimeofday-y),) - CFLAGS_vgettimeofday.o += -include $(c-gettimeofday-y) -endif - -ifneq ($(c-getrandom-y),) - CFLAGS_vgetrandom.o += -include $(c-getrandom-y) -endif - targets += vdso.lds CPPFLAGS_vdso.lds += -P -C -U$(ARCH) diff --git a/arch/arm64/kernel/vdso/vgetrandom.c b/arch/arm64/kernel/vdso/vgetrandom.c index 832fe195292b..e77f45e1fa1d 100644 --- a/arch/arm64/kernel/vdso/vgetrandom.c +++ b/arch/arm64/kernel/vdso/vgetrandom.c @@ -2,6 +2,8 @@ #include +#include "../../../../lib/vdso/getrandom.c" + typeof(__cvdso_getrandom) __kernel_getrandom; ssize_t __kernel_getrandom(void *buffer, size_t len, unsigned int flags, void *opaque_state, size_t opaque_len) diff --git a/arch/arm64/kernel/vdso/vgettimeofday.c b/arch/arm64/kernel/vdso/vgettimeofday.c index 9941c5b04f15..090e6a45751d 100644 --- a/arch/arm64/kernel/vdso/vgettimeofday.c +++ b/arch/arm64/kernel/vdso/vgettimeofday.c @@ -6,6 +6,8 @@ * */ +#include "../../../../lib/vdso/gettimeofday.c" + int __kernel_clock_gettime(clockid_t clock, struct __kernel_timespec *ts); int __kernel_gettimeofday(struct __kernel_old_timeval *tv, struct timezone *tz); int __kernel_clock_getres(clockid_t clock_id, struct __kernel_timespec *res); diff --git a/arch/arm64/kernel/vdso32/Makefile b/arch/arm64/kernel/vdso32/Makefile index 00efdc5d2354..f521d5e4b5cd 100644 --- a/arch/arm64/kernel/vdso32/Makefile +++ b/arch/arm64/kernel/vdso32/Makefile @@ -95,10 +95,6 @@ hostprogs := $(munge) c-obj-vdso := note.o c-obj-vdso-gettimeofday := vgettimeofday.o -ifneq ($(c-gettimeofday-y),) -VDSO_CFLAGS_gettimeofday_o += -include $(c-gettimeofday-y) -endif - VDSO_CFLAGS_REMOVE_vgettimeofday.o = $(CC_FLAGS_FTRACE) -Os # Build rules diff --git a/arch/arm64/kernel/vdso32/vgettimeofday.c b/arch/arm64/kernel/vdso32/vgettimeofday.c index 12d0255cc2cf..1e3f141f0fd4 100644 --- a/arch/arm64/kernel/vdso32/vgettimeofday.c +++ b/arch/arm64/kernel/vdso32/vgettimeofday.c @@ -8,6 +8,8 @@ #define BUILD_VDSO32_64 #include +#include "../../../../lib/vdso/gettimeofday.c" + #ifdef CONFIG_COMPAT_32BIT_TIME int __vdso_clock_gettime(clockid_t clock, struct old_timespec32 *ts) -- 2.56.1