16 #ifndef __POWERPC_CPUTIME_H
17 #define __POWERPC_CPUTIME_H
19 #ifndef CONFIG_VIRT_CPU_ACCOUNTING
22 static inline void setup_cputime_one_jiffy(
void) { }
26 #include <linux/types.h>
27 #include <linux/time.h>
28 #include <asm/div64.h>
30 #include <asm/param.h>
45 extern u64 __cputime_jiffies_factor;
51 return mulhdu((
__force u64) ct, __cputime_jiffies_factor);
83 static inline void setup_cputime_one_jiffy(
void)
107 return mulhdu((
__force u64) ct, __cputime_jiffies_factor);
113 extern u64 __cputime_usec_factor;
117 return mulhdu((
__force u64) ct, __cputime_usec_factor);
137 #define usecs_to_cputime64(us) usecs_to_cputime(us)
142 extern u64 __cputime_sec_factor;
146 return mulhdu((
__force u64) ct, __cputime_sec_factor);
164 x = (
u64) frac * 1000000000;
188 x = (
u64) frac * 1000000;
205 extern u64 __cputime_clockt_factor;
209 return mulhdu((
__force u64) ct, __cputime_clockt_factor);
229 #define cputime64_to_clock_t(ct) cputime_to_clock_t((cputime_t)(ct))