summaryrefslogtreecommitdiff
path: root/src/arch
diff options
context:
space:
mode:
Diffstat (limited to 'src/arch')
-rw-r--r--src/arch/x86/timestamp.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/arch/x86/timestamp.c b/src/arch/x86/timestamp.c
index 9df505a570..d308146070 100644
--- a/src/arch/x86/timestamp.c
+++ b/src/arch/x86/timestamp.c
@@ -24,3 +24,16 @@ uint64_t timestamp_get(void)
{
return rdtscll();
}
+
+unsigned long __attribute__((weak)) tsc_freq_mhz(void)
+{
+ /* Default to not knowing TSC frequency. cbmem will have to fallback
+ * on trying to determine it in userspace. */
+ return 0;
+}
+
+int timestamp_tick_freq_mhz(void)
+{
+ /* Chipsets that have a constant TSC provide this value correctly. */
+ return tsc_freq_mhz();
+}