aboutsummaryrefslogtreecommitdiff
path: root/arch/powerpc/include/asm/timex.h
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc/include/asm/timex.h')
-rw-r--r--arch/powerpc/include/asm/timex.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/arch/powerpc/include/asm/timex.h b/arch/powerpc/include/asm/timex.h
index c55e14f7ef4..2fe7460cbf9 100644
--- a/arch/powerpc/include/asm/timex.h
+++ b/arch/powerpc/include/asm/timex.h
@@ -14,6 +14,8 @@
typedef unsigned long cycles_t;
+extern unsigned long tb_ticks_per_sec;
+
static inline cycles_t get_cycles(void)
{
#ifdef __powerpc64__
@@ -46,5 +48,15 @@ static inline cycles_t get_cycles(void)
#endif
}
+static inline cycles_t get_cycles_rate(void)
+{
+ return tb_ticks_per_sec;
+}
+
+static inline void get_cycles_barrier(void)
+{
+ isync();
+}
+
#endif /* __KERNEL__ */
#endif /* _ASM_POWERPC_TIMEX_H */