Rev 2967 | Rev 3482 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2967 | Rev 3031 | ||
---|---|---|---|
Line 69... | Line 69... | ||
69 | 69 | ||
70 | /* TICK_USEC_TO_NSEC is the time between ticks in nsec assuming real ACTHZ and */ |
70 | /* TICK_USEC_TO_NSEC is the time between ticks in nsec assuming real ACTHZ and */ |
71 | /* a value TUSEC for TICK_USEC (can be set bij adjtimex) */ |
71 | /* a value TUSEC for TICK_USEC (can be set bij adjtimex) */ |
Line 72... | Line -... | ||
72 | #define TICK_USEC_TO_NSEC(TUSEC) (SH_DIV (TUSEC * USER_HZ * 1000, ACTHZ, 8)) |
- | |
73 | - | ||
74 | #define jiffies GetTimerTicks() |
- | |
75 | - | ||
76 | #if (BITS_PER_LONG < 64) |
- | |
77 | u64 get_jiffies_64(void); |
72 | #define TICK_USEC_TO_NSEC(TUSEC) (SH_DIV (TUSEC * USER_HZ * 1000, ACTHZ, 8)) |
78 | #else |
73 | |
79 | static inline u64 get_jiffies_64(void) |
74 | static inline u64 get_jiffies_64(void) |
80 | { |
75 | { |
81 | return (u64)jiffies; |
- | |
Line 82... | Line 76... | ||
82 | } |
76 | return (u64)GetTimerTicks(); |
83 | #endif |
77 | } |
84 | 78 | ||
85 | /* |
79 | /* |
Line 293... | Line 287... | ||
293 | extern void jiffies_to_timespec(const unsigned long jiffies, |
287 | extern void jiffies_to_timespec(const unsigned long jiffies, |
294 | struct timespec *value); |
288 | struct timespec *value); |
295 | extern unsigned long timeval_to_jiffies(const struct timeval *value); |
289 | extern unsigned long timeval_to_jiffies(const struct timeval *value); |
296 | extern void jiffies_to_timeval(const unsigned long jiffies, |
290 | extern void jiffies_to_timeval(const unsigned long jiffies, |
297 | struct timeval *value); |
291 | struct timeval *value); |
- | 292 | ||
298 | extern clock_t jiffies_to_clock_t(unsigned long x); |
293 | extern clock_t jiffies_to_clock_t(unsigned long x); |
- | 294 | static inline clock_t jiffies_delta_to_clock_t(long delta) |
|
- | 295 | { |
|
- | 296 | return jiffies_to_clock_t(max(0L, delta)); |
|
- | 297 | } |
|
- | 298 | ||
299 | extern unsigned long clock_t_to_jiffies(unsigned long x); |
299 | extern unsigned long clock_t_to_jiffies(unsigned long x); |
300 | extern u64 jiffies_64_to_clock_t(u64 x); |
300 | extern u64 jiffies_64_to_clock_t(u64 x); |
301 | extern u64 nsec_to_clock_t(u64 x); |
301 | extern u64 nsec_to_clock_t(u64 x); |
302 | extern u64 nsecs_to_jiffies64(u64 n); |
302 | extern u64 nsecs_to_jiffies64(u64 n); |
303 | extern unsigned long nsecs_to_jiffies(u64 n); |
303 | extern unsigned long nsecs_to_jiffies(u64 n); |