summaryrefslogtreecommitdiff
path: root/include/linux/clocksource_ids.h
diff options
context:
space:
mode:
authorPeter Hilber <peter.hilber@opensynergy.com>2024-02-01 02:04:48 +0100
committerThomas Gleixner <tglx@linutronix.de>2024-02-07 17:05:21 +0100
commita2c1fe72062a5dd69de4dfe892f6436d6c0479dd (patch)
tree4a6f1f7136f96a078e23b881cba855e901b828d2 /include/linux/clocksource_ids.h
parent93630d6df7507fa4e664110b1878c06a0c00b0b9 (diff)
x86/tsc: Add clocksource ID, set system_counterval_t.cs_id
Add a clocksource ID for TSC and a distinct one for the early TSC. Use distinct IDs for TSC and early TSC, since those also have distinct clocksource structs. This should help to keep existing semantics when comparing clocksources. Also, set the recently added struct system_counterval_t member cs_id to the TSC ID in the cases where the clocksource member is being set to the TSC clocksource. In the future, get_device_system_crosststamp() will compare the clocksource ID in struct system_counterval_t, rather than the clocksource. For the x86 ART related code, system_counterval_t.cs == NULL corresponds to system_counterval_t.cs_id == CSID_GENERIC (0). Signed-off-by: Peter Hilber <peter.hilber@opensynergy.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/r/20240201010453.2212371-4-peter.hilber@opensynergy.com
Diffstat (limited to 'include/linux/clocksource_ids.h')
-rw-r--r--include/linux/clocksource_ids.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/clocksource_ids.h b/include/linux/clocksource_ids.h
index 16775d7d8f8d..f8467946e9ee 100644
--- a/include/linux/clocksource_ids.h
+++ b/include/linux/clocksource_ids.h
@@ -6,6 +6,8 @@
enum clocksource_ids {
CSID_GENERIC = 0,
CSID_ARM_ARCH_COUNTER,
+ CSID_X86_TSC_EARLY,
+ CSID_X86_TSC,
CSID_MAX,
};