1 /* SPDX-License-Identifier: GPL-2.0 */ << 2 #define TIMER_RETRY 1 1 #define TIMER_RETRY 1 3 2 4 struct k_clock { 3 struct k_clock { 5 int (*clock_getres)(const clockid_ 4 int (*clock_getres)(const clockid_t which_clock, 6 struct timespe 5 struct timespec64 *tp); 7 int (*clock_set)(const clockid_t w 6 int (*clock_set)(const clockid_t which_clock, 8 const struct time 7 const struct timespec64 *tp); 9 /* Returns the clock value in the curr !! 8 int (*clock_get)(const clockid_t which_clock, 10 int (*clock_get_timespec)(const cl !! 9 struct timespec64 *tp); 11 struct t !! 10 int (*clock_adj)(const clockid_t which_clock, struct timex *tx); 12 /* Returns the clock value in the root << 13 ktime_t (*clock_get_ktime)(const clock << 14 int (*clock_adj)(const clockid_t w << 15 int (*timer_create)(struct k_itime 11 int (*timer_create)(struct k_itimer *timer); 16 int (*nsleep)(const clockid_t whic 12 int (*nsleep)(const clockid_t which_clock, int flags, 17 const struct timespe 13 const struct timespec64 *); 18 int (*timer_set)(struct k_itimer * 14 int (*timer_set)(struct k_itimer *timr, int flags, 19 struct itimerspec 15 struct itimerspec64 *new_setting, 20 struct itimerspec 16 struct itimerspec64 *old_setting); 21 int (*timer_del)(struct k_itimer * 17 int (*timer_del)(struct k_itimer *timr); 22 void (*timer_get)(struct k_itimer * 18 void (*timer_get)(struct k_itimer *timr, 23 struct itimerspec 19 struct itimerspec64 *cur_setting); 24 void (*timer_rearm)(struct k_itimer 20 void (*timer_rearm)(struct k_itimer *timr); 25 s64 (*timer_forward)(struct k_itim !! 21 int (*timer_forward)(struct k_itimer *timr, ktime_t now); 26 ktime_t (*timer_remaining)(struct k_it 22 ktime_t (*timer_remaining)(struct k_itimer *timr, ktime_t now); 27 int (*timer_try_to_cancel)(struct 23 int (*timer_try_to_cancel)(struct k_itimer *timr); 28 void (*timer_arm)(struct k_itimer * 24 void (*timer_arm)(struct k_itimer *timr, ktime_t expires, 29 bool absolute, bo 25 bool absolute, bool sigev_none); 30 void (*timer_wait_running)(struct k << 31 }; 26 }; 32 27 33 extern const struct k_clock clock_posix_cpu; 28 extern const struct k_clock clock_posix_cpu; 34 extern const struct k_clock clock_posix_dynami 29 extern const struct k_clock clock_posix_dynamic; 35 extern const struct k_clock clock_process; 30 extern const struct k_clock clock_process; 36 extern const struct k_clock clock_thread; 31 extern const struct k_clock clock_thread; 37 extern const struct k_clock alarm_clock; 32 extern const struct k_clock alarm_clock; 38 33 39 int posix_timer_queue_signal(struct k_itimer * !! 34 int posix_timer_event(struct k_itimer *timr, int si_private); 40 35 41 void common_timer_get(struct k_itimer *timr, s 36 void common_timer_get(struct k_itimer *timr, struct itimerspec64 *cur_setting); 42 int common_timer_set(struct k_itimer *timr, in 37 int common_timer_set(struct k_itimer *timr, int flags, 43 struct itimerspec64 *new_ 38 struct itimerspec64 *new_setting, 44 struct itimerspec64 *old_ 39 struct itimerspec64 *old_setting); 45 void posix_timer_set_common(struct k_itimer *t << 46 int common_timer_del(struct k_itimer *timer); 40 int common_timer_del(struct k_itimer *timer); 47 41
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.