From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A02CB480346; Tue, 7 Jul 2026 21:54:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.142.43.55 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783461290; cv=none; b=YF1BUsiAqZunaF6aL5cIX6ep6UTNIHhpigFf72L+B+OyhPG7boSIVFseMKKNSgnKby/T2wmEmHr3AcDUk4hQkYotiYuAf8taBT3rupjlbeTLhTJNxRfaIKVR1AtogzEvdO5kfzaDljMXxd9U9FVCKwg+/5/X81mhEF635cP199c= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783461290; c=relaxed/simple; bh=U1jLAFP+yRIfETsuwdM8WdrueGSGSrejG5JaU7c7iIk=; h=Date:From:To:Subject:Cc:In-Reply-To:References:MIME-Version: Message-ID:Content-Type; b=rZGFIp0Z4qiV9b3M+bMFuKveWn9OPVUOuVeAaYZcGCSDX4SFycpJFTaWNrUrQ5ba3z3HgmboHXcN+YEDu99vGnkkuUtc9MwiJRjAZQ0DePD1r9i5XSFrcP2ZdSFqHUpTIqbPTJxbW4y3K19jIE4Wh+m2qRHO9PyLRz/X/FYSyDQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=E26svSnh; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=jl6KtyD/; arc=none smtp.client-ip=193.142.43.55 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.b="E26svSnh"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="jl6KtyD/" Date: Tue, 07 Jul 2026 21:54:45 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1783461287; h=from:from:sender:sender:reply-to: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=GkJEIBfcpr5uiYYZoAtQ8FzxXvvyq7vFy3u08Ix/VNE=; b=E26svSnhOad2oQ0qHEFx84BrQv8tVU3g8mdM5PyPK0QgDACDidVFjJKc4+ATb4RwQs+JTJ UVflnbJXdYM740jiBNrrKhCAH/jjlCiZByHaclcHahxk4VIuohCGMI0zK+CtGi35xRrpJA EXGgQF33X7x0xlpzkUlx/A3KNZ6H0girWNoEmHFqAyqcDjLH3xOGGmt8+zHSNrdmiTzWQf AuGEZRo0+0JjkjRORtTFCyPJ2ppfg/GuEC+RplPE8SRe0IARbva7wJaTYzx7oYAHqByCp6 6f+IbWWWpZDkJy/jxV3BJ8i+c+oCeghc73FKIeFCMAeAQDT40KOAA4VFAKiHsA== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1783461287; h=from:from:sender:sender:reply-to: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=GkJEIBfcpr5uiYYZoAtQ8FzxXvvyq7vFy3u08Ix/VNE=; b=jl6KtyD/rMQdqK6ydwpc3e+M34rDppkbpdzdroOEh0F5UYHqWKkqVCIq+mvef6cljwBI16 bcgoJZtKb6UxtxDQ== From: tip-bot2 for Thomas =?utf-8?q?Wei=C3=9Fschuh?= Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: timers/vdso] x86/vdso: Respect COMPAT_32BIT_TIME Cc: thomas.weissschuh@linutronix.de, Thomas Gleixner , Arnd Bergmann , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20260702-vdso-compat_32bit_time-v3-3-db9f36d8d432@linutronix.de> References: <20260702-vdso-compat_32bit_time-v3-3-db9f36d8d432@linutronix.de> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-ID: <178346128592.744054.7212552064728580640.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Precedence: bulk Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable The following commit has been merged into the timers/vdso branch of tip: Commit-ID: 1a4660da3130f7b1e88d8afa3c4a9982c14bcea6 Gitweb: https://git.kernel.org/tip/1a4660da3130f7b1e88d8afa3c4a9982c14= bcea6 Author: Thomas Wei=C3=9Fschuh AuthorDate: Thu, 02 Jul 2026 10:21:27 +02:00 Committer: Thomas Gleixner CommitterDate: Tue, 07 Jul 2026 23:52:53 +02:00 x86/vdso: Respect COMPAT_32BIT_TIME If CONFIG_COMPAT_32BIT_TIME is disabled then the vDSO should not provide any 32-bit time related functionality. This is the intended effect of the kconfig option and also the fallback system calls would also not be implemented. Signed-off-by: Thomas Wei=C3=9Fschuh Signed-off-by: Thomas Gleixner Reviewed-by: Arnd Bergmann Link: https://patch.msgid.link/20260702-vdso-compat_32bit_time-v3-3-db9f36d8d= 432@linutronix.de --- arch/x86/entry/vdso/common/vclock_gettime.c | 20 ++++++++++++-------- arch/x86/entry/vdso/vdso32/vdso32.lds.S | 2 ++- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/arch/x86/entry/vdso/common/vclock_gettime.c b/arch/x86/entry/vds= o/common/vclock_gettime.c index 57066f3..304dbd1 100644 --- a/arch/x86/entry/vdso/common/vclock_gettime.c +++ b/arch/x86/entry/vdso/common/vclock_gettime.c @@ -15,6 +15,7 @@ =20 #include "lib/vdso/gettimeofday.c" =20 +#if defined(__x86_64__) || defined(CONFIG_COMPAT_32BIT_TIME) int __vdso_gettimeofday(struct __kernel_old_timeval *tv, struct timezone *tz) { return __cvdso_gettimeofday(tv, tz); @@ -29,6 +30,7 @@ __kernel_old_time_t __vdso_time(__kernel_old_time_t *t) } =20 __kernel_old_time_t time(__kernel_old_time_t *t) __attribute__((weak, alias(= "__vdso_time"))); +#endif /* CONFIG_COMPAT_32BIT_TIME */ =20 =20 #if defined(CONFIG_X86_64) && !defined(BUILD_VDSO32_64) @@ -51,6 +53,7 @@ int clock_getres(clockid_t, struct __kernel_timespec *) =20 #else /* i386 only */ +#ifdef CONFIG_COMPAT_32BIT_TIME int __vdso_clock_gettime(clockid_t clock, struct old_timespec32 *ts) { return __cvdso_clock_gettime32(clock, ts); @@ -59,14 +62,6 @@ int __vdso_clock_gettime(clockid_t clock, struct old_times= pec32 *ts) int clock_gettime(clockid_t, struct old_timespec32 *) __attribute__((weak, alias("__vdso_clock_gettime"))); =20 -int __vdso_clock_gettime64(clockid_t clock, struct __kernel_timespec *ts) -{ - return __cvdso_clock_gettime(clock, ts); -} - -int clock_gettime64(clockid_t, struct __kernel_timespec *) - __attribute__((weak, alias("__vdso_clock_gettime64"))); - int __vdso_clock_getres(clockid_t clock, struct old_timespec32 *res) { return __cvdso_clock_getres_time32(clock, res); @@ -74,6 +69,15 @@ int __vdso_clock_getres(clockid_t clock, struct old_timesp= ec32 *res) =20 int clock_getres(clockid_t, struct old_timespec32 *) __attribute__((weak, alias("__vdso_clock_getres"))); +#endif /* CONFIG_COMPAT_32BIT_TIME */ + +int __vdso_clock_gettime64(clockid_t clock, struct __kernel_timespec *ts) +{ + return __cvdso_clock_gettime(clock, ts); +} + +int clock_gettime64(clockid_t, struct __kernel_timespec *) + __attribute__((weak, alias("__vdso_clock_gettime64"))); =20 int __vdso_clock_getres_time64(clockid_t clock, struct __kernel_timespec *ts) { diff --git a/arch/x86/entry/vdso/vdso32/vdso32.lds.S b/arch/x86/entry/vdso/vd= so32/vdso32.lds.S index cee8f7f..0062919 100644 --- a/arch/x86/entry/vdso/vdso32/vdso32.lds.S +++ b/arch/x86/entry/vdso/vdso32/vdso32.lds.S @@ -23,10 +23,12 @@ VERSION { LINUX_2.6 { global: +#ifdef CONFIG_COMPAT_32BIT_TIME __vdso_clock_gettime; __vdso_gettimeofday; __vdso_time; __vdso_clock_getres; +#endif /* CONFIG_COMPAT_32BIT_TIME */ __vdso_clock_gettime64; __vdso_clock_getres_time64; __vdso_getcpu;