summaryrefslogtreecommitdiff
path: root/arch/arm/include/asm/arch-octeontx2/clock.h
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/include/asm/arch-octeontx2/clock.h')
-rw-r--r--arch/arm/include/asm/arch-octeontx2/clock.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/arch/arm/include/asm/arch-octeontx2/clock.h b/arch/arm/include/asm/arch-octeontx2/clock.h
new file mode 100644
index 0000000000..7be8852a55
--- /dev/null
+++ b/arch/arm/include/asm/arch-octeontx2/clock.h
@@ -0,0 +1,24 @@
+/* SPDX-License-Identifier: GPL-2.0
+ *
+ * Copyright (C) 2018 Marvell International Ltd.
+ *
+ * https://spdx.org/licenses
+ */
+
+#ifndef __CLOCK_H__
+
+/** System PLL reference clock */
+#define PLL_REF_CLK 50000000 /* 50 MHz */
+#define NS_PER_REF_CLK_TICK (1000000000 / PLL_REF_CLK)
+
+/**
+ * Returns the I/O clock speed in Hz
+ */
+u64 octeontx_get_io_clock(void);
+
+/**
+ * Returns the core clock speed in Hz
+ */
+u64 octeontx_get_core_clock(void);
+
+#endif /* __CLOCK_H__ */