diff options
Diffstat (limited to 'include/linux/posix-timers.h')
-rw-r--r-- | include/linux/posix-timers.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/include/linux/posix-timers.h b/include/linux/posix-timers.h index 9d6ffe2c92e5..d51243ae0726 100644 --- a/include/linux/posix-timers.h +++ b/include/linux/posix-timers.h | |||
@@ -32,7 +32,7 @@ struct cpu_timer_list { | |||
32 | #define CPUCLOCK_PID(clock) ((pid_t) ~((clock) >> 3)) | 32 | #define CPUCLOCK_PID(clock) ((pid_t) ~((clock) >> 3)) |
33 | #define CPUCLOCK_PERTHREAD(clock) \ | 33 | #define CPUCLOCK_PERTHREAD(clock) \ |
34 | (((clock) & (clockid_t) CPUCLOCK_PERTHREAD_MASK) != 0) | 34 | (((clock) & (clockid_t) CPUCLOCK_PERTHREAD_MASK) != 0) |
35 | #define CPUCLOCK_PID_MASK 7 | 35 | |
36 | #define CPUCLOCK_PERTHREAD_MASK 4 | 36 | #define CPUCLOCK_PERTHREAD_MASK 4 |
37 | #define CPUCLOCK_WHICH(clock) ((clock) & (clockid_t) CPUCLOCK_CLOCK_MASK) | 37 | #define CPUCLOCK_WHICH(clock) ((clock) & (clockid_t) CPUCLOCK_CLOCK_MASK) |
38 | #define CPUCLOCK_CLOCK_MASK 3 | 38 | #define CPUCLOCK_CLOCK_MASK 3 |
@@ -48,6 +48,9 @@ struct cpu_timer_list { | |||
48 | #define MAKE_THREAD_CPUCLOCK(tid, clock) \ | 48 | #define MAKE_THREAD_CPUCLOCK(tid, clock) \ |
49 | MAKE_PROCESS_CPUCLOCK((tid), (clock) | CPUCLOCK_PERTHREAD_MASK) | 49 | MAKE_PROCESS_CPUCLOCK((tid), (clock) | CPUCLOCK_PERTHREAD_MASK) |
50 | 50 | ||
51 | #define FD_TO_CLOCKID(fd) ((~(clockid_t) (fd) << 3) | CLOCKFD) | ||
52 | #define CLOCKID_TO_FD(clk) ((unsigned int) ~((clk) >> 3)) | ||
53 | |||
51 | /* POSIX.1b interval timer structure. */ | 54 | /* POSIX.1b interval timer structure. */ |
52 | struct k_itimer { | 55 | struct k_itimer { |
53 | struct list_head list; /* free/ allocate list */ | 56 | struct list_head list; /* free/ allocate list */ |
@@ -100,6 +103,7 @@ struct k_clock { | |||
100 | }; | 103 | }; |
101 | 104 | ||
102 | extern struct k_clock clock_posix_cpu; | 105 | extern struct k_clock clock_posix_cpu; |
106 | extern struct k_clock clock_posix_dynamic; | ||
103 | 107 | ||
104 | void posix_timers_register_clock(const clockid_t clock_id, struct k_clock *new_clock); | 108 | void posix_timers_register_clock(const clockid_t clock_id, struct k_clock *new_clock); |
105 | 109 | ||