summaryrefslogtreecommitdiff
path: root/include/vdso
diff options
context:
space:
mode:
authorThomas Weißschuh <thomas.weissschuh@linutronix.de>2025-07-01 10:58:04 +0200
committerThomas Gleixner <tglx@linutronix.de>2025-07-18 13:45:32 +0200
commit9b7fc3f14576c268f62fe0b882fac5e61239b659 (patch)
treed95ef8658d48429c608884dbc780000aebe58071 /include/vdso
parent562f03ed967dc65e513a3e2e9821f656d5333b8e (diff)
vdso: Introduce aux_clock_resolution_ns()
Move the constant resolution to a shared header, so the vDSO can use it and return it without going through a syscall. Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250701-vdso-auxclock-v1-10-df7d9f87b9b8@linutronix.de
Diffstat (limited to 'include/vdso')
-rw-r--r--include/vdso/auxclock.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/vdso/auxclock.h b/include/vdso/auxclock.h
new file mode 100644
index 000000000000..6d6e74cbc400
--- /dev/null
+++ b/include/vdso/auxclock.h
@@ -0,0 +1,13 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+#ifndef _VDSO_AUXCLOCK_H
+#define _VDSO_AUXCLOCK_H
+
+#include <uapi/linux/time.h>
+#include <uapi/linux/types.h>
+
+static __always_inline u64 aux_clock_resolution_ns(void)
+{
+ return 1;
+}
+
+#endif /* _VDSO_AUXCLOCK_H */