]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
x86/vdso: Provide clock_getres_time64() for x86-32
authorThomas Weißschuh <thomas.weissschuh@linutronix.de>
Tue, 23 Dec 2025 06:59:16 +0000 (07:59 +0100)
committerThomas Gleixner <tglx@kernel.org>
Tue, 13 Jan 2026 13:42:23 +0000 (14:42 +0100)
For consistency with __vdso_clock_gettime64() there should also be a
64-bit variant of clock_getres(). This will allow the extension of
CONFIG_COMPAT_32BIT_TIME to the vDSO and finally the removal of 32-bit
time types from the kernel and UAPI.

Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
Signed-off-by: Thomas Gleixner <tglx@kernel.org>
Link: https://patch.msgid.link/20251223-vdso-compat-time32-v1-5-97ea7a06a543@linutronix.de
arch/x86/entry/vdso/vclock_gettime.c
arch/x86/entry/vdso/vdso32/vdso32.lds.S

index 0debc194bd7819959c30ca0e1ae98035ee046d8b..027b7e88d753a762342118ed5daa61ac17c99664 100644 (file)
@@ -74,4 +74,12 @@ int __vdso_clock_getres(clockid_t clock, struct old_timespec32 *res)
 
 int clock_getres(clockid_t, struct old_timespec32 *)
        __attribute__((weak, alias("__vdso_clock_getres")));
+
+int __vdso_clock_getres_time64(clockid_t clock, struct __kernel_timespec *ts)
+{
+       return __cvdso_clock_getres(clock, ts);
+}
+
+int clock_getres_time64(clockid_t, struct __kernel_timespec *)
+       __attribute__((weak, alias("__vdso_clock_getres_time64")));
 #endif
index 8a3be07006bb63f164ce861044c8a28d3657dcd6..6f977c103584612876bb03dd758f33b3d40561f2 100644 (file)
@@ -28,6 +28,7 @@ VERSION
                __vdso_time;
                __vdso_clock_getres;
                __vdso_clock_gettime64;
+               __vdso_clock_getres_time64;
                __vdso_getcpu;
        };