summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@kernel.org>2026-05-29 23:00:32 +0300
committerThomas Gleixner <tglx@kernel.org>2026-06-04 12:04:16 +0300
commite3b8d03faa4d266d19ff7a7534e7bf810ff681cf (patch)
tree32c9224528512c82a64d052149eda73902a2982e /include/linux
parent6c14771816435a7ecf52d981a341e2de21463268 (diff)
downloadlinux-e3b8d03faa4d266d19ff7a7534e7bf810ff681cf.tar.xz
timekeeping: Add CLOCK ID to system_device_crosststamp
The normal capture for system/device cross timestamps is CLOCK_REALTIME, but that's meaningless for AUX clocks. Add a clock_id field to struct system_device_crosststamp and initialize it with CLOCK_REALTIME at the two places which prepare for cross timestamps. After the related code has been cleaned up, the core code will honor the clock_id field when calculating the system time from the system counter snapshot. No functional change. Signed-off-by: Thomas Gleixner <tglx@kernel.org> Tested-by: David Woodhouse <dwmw@amazon.co.uk> Tested-by: Arthur Kiyanovski <akiyano@amazon.com> Reviewed-by: David Woodhouse <dwmw@amazon.co.uk> Reviewed-by: Jacob Keller <jacob.e.keller@intel.com> Link: https://patch.msgid.link/20260529195557.482153523@kernel.org
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/timekeeping.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/timekeeping.h b/include/linux/timekeeping.h
index 3867db65f391..fff6d9e319c4 100644
--- a/include/linux/timekeeping.h
+++ b/include/linux/timekeeping.h
@@ -315,12 +315,14 @@ struct system_counterval_t {
/**
* struct system_device_crosststamp - system/device cross-timestamp
* (synchronized capture)
+ * @clock_id: System time Clock ID to capture
* @device: Device time
* @sys_counter: Clocksource counter value simultaneous with device time
* @sys_realtime: Realtime simultaneous with device time
* @sys_monoraw: Monotonic raw simultaneous with device time
*/
struct system_device_crosststamp {
+ clockid_t clock_id;
ktime_t device;
struct system_counterval_t sys_counter;
ktime_t sys_realtime;