Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0 */
0002 #ifndef _ASM_POWERPC_TIMEX_H
0003 #define _ASM_POWERPC_TIMEX_H
0004 
0005 #ifdef __KERNEL__
0006 
0007 /*
0008  * PowerPC architecture timex specifications
0009  */
0010 
0011 #include <asm/cputable.h>
0012 #include <asm/vdso/timebase.h>
0013 
0014 #define CLOCK_TICK_RATE 1024000 /* Underlying HZ */
0015 
0016 typedef unsigned long cycles_t;
0017 
0018 static inline cycles_t get_cycles(void)
0019 {
0020     return mftb();
0021 }
0022 #define get_cycles get_cycles
0023 
0024 #endif  /* __KERNEL__ */
0025 #endif  /* _ASM_POWERPC_TIMEX_H */