timr 154 drivers/rtc/rtc-cadence.c u32 timr, calr, stsr; timr 161 drivers/rtc/rtc-cadence.c timr = cdns_rtc_time2reg(tm); timr 171 drivers/rtc/rtc-cadence.c writel(timr, crtc->regs + CDNS_RTC_TIMR); timr 15 drivers/tty/serial/sunsab.h u8 timr; /* Timer Register */ timr 46 drivers/tty/serial/sunsab.h u8 timr; timr 82 drivers/tty/serial/sunsab.h u8 timr; timr 576 kernel/time/alarmtimer.c static void alarm_timer_rearm(struct k_itimer *timr) timr 578 kernel/time/alarmtimer.c struct alarm *alarm = &timr->it.alarm.alarmtimer; timr 580 kernel/time/alarmtimer.c timr->it_overrun += alarm_forward_now(alarm, timr->it_interval); timr 589 kernel/time/alarmtimer.c static s64 alarm_timer_forward(struct k_itimer *timr, ktime_t now) timr 591 kernel/time/alarmtimer.c struct alarm *alarm = &timr->it.alarm.alarmtimer; timr 593 kernel/time/alarmtimer.c return alarm_forward(alarm, timr->it_interval, now); timr 601 kernel/time/alarmtimer.c static ktime_t alarm_timer_remaining(struct k_itimer *timr, ktime_t now) timr 603 kernel/time/alarmtimer.c struct alarm *alarm = &timr->it.alarm.alarmtimer; timr 612 kernel/time/alarmtimer.c static int alarm_timer_try_to_cancel(struct k_itimer *timr) timr 614 kernel/time/alarmtimer.c return alarm_try_to_cancel(&timr->it.alarm.alarmtimer); timr 625 kernel/time/alarmtimer.c static void alarm_timer_wait_running(struct k_itimer *timr) timr 627 kernel/time/alarmtimer.c hrtimer_cancel_wait_running(&timr->it.alarm.alarmtimer.timer); timr 637 kernel/time/alarmtimer.c static void alarm_timer_arm(struct k_itimer *timr, ktime_t expires, timr 640 kernel/time/alarmtimer.c struct alarm *alarm = &timr->it.alarm.alarmtimer; timr 648 kernel/time/alarmtimer.c alarm_start(&timr->it.alarm.alarmtimer, expires); timr 162 kernel/time/posix-timers.c static inline void unlock_timer(struct k_itimer *timr, unsigned long flags) timr 164 kernel/time/posix-timers.c spin_unlock_irqrestore(&timr->it_lock, flags); timr 260 kernel/time/posix-timers.c static inline int timer_overrun_to_int(struct k_itimer *timr, int baseval) timr 262 kernel/time/posix-timers.c s64 sum = timr->it_overrun_last + (s64)baseval; timr 267 kernel/time/posix-timers.c static void common_hrtimer_rearm(struct k_itimer *timr) timr 269 kernel/time/posix-timers.c struct hrtimer *timer = &timr->it.real.timer; timr 271 kernel/time/posix-timers.c timr->it_overrun += hrtimer_forward(timer, timer->base->get_time(), timr 272 kernel/time/posix-timers.c timr->it_interval); timr 289 kernel/time/posix-timers.c struct k_itimer *timr; timr 292 kernel/time/posix-timers.c timr = lock_timer(info->si_tid, &flags); timr 293 kernel/time/posix-timers.c if (!timr) timr 296 kernel/time/posix-timers.c if (timr->it_interval && timr->it_requeue_pending == info->si_sys_private) { timr 297 kernel/time/posix-timers.c timr->kclock->timer_rearm(timr); timr 299 kernel/time/posix-timers.c timr->it_active = 1; timr 300 kernel/time/posix-timers.c timr->it_overrun_last = timr->it_overrun; timr 301 kernel/time/posix-timers.c timr->it_overrun = -1LL; timr 302 kernel/time/posix-timers.c ++timr->it_requeue_pending; timr 304 kernel/time/posix-timers.c info->si_overrun = timer_overrun_to_int(timr, info->si_overrun); timr 307 kernel/time/posix-timers.c unlock_timer(timr, flags); timr 310 kernel/time/posix-timers.c int posix_timer_event(struct k_itimer *timr, int si_private) timr 325 kernel/time/posix-timers.c timr->sigq->info.si_sys_private = si_private; timr 327 kernel/time/posix-timers.c type = !(timr->it_sigev_notify & SIGEV_THREAD_ID) ? PIDTYPE_TGID : PIDTYPE_PID; timr 328 kernel/time/posix-timers.c ret = send_sigqueue(timr->sigq, timr->it_pid, type); timr 342 kernel/time/posix-timers.c struct k_itimer *timr; timr 347 kernel/time/posix-timers.c timr = container_of(timer, struct k_itimer, it.real.timer); timr 348 kernel/time/posix-timers.c spin_lock_irqsave(&timr->it_lock, flags); timr 350 kernel/time/posix-timers.c timr->it_active = 0; timr 351 kernel/time/posix-timers.c if (timr->it_interval != 0) timr 352 kernel/time/posix-timers.c si_private = ++timr->it_requeue_pending; timr 354 kernel/time/posix-timers.c if (posix_timer_event(timr, si_private)) { timr 360 kernel/time/posix-timers.c if (timr->it_interval != 0) { timr 389 kernel/time/posix-timers.c if (timr->it_interval < kj) timr 393 kernel/time/posix-timers.c timr->it_overrun += hrtimer_forward(timer, now, timr 394 kernel/time/posix-timers.c timr->it_interval); timr 396 kernel/time/posix-timers.c ++timr->it_requeue_pending; timr 397 kernel/time/posix-timers.c timr->it_active = 1; timr 401 kernel/time/posix-timers.c unlock_timer(timr, flags); timr 590 kernel/time/posix-timers.c struct k_itimer *timr; timr 600 kernel/time/posix-timers.c timr = posix_timer_by_id(timer_id); timr 601 kernel/time/posix-timers.c if (timr) { timr 602 kernel/time/posix-timers.c spin_lock_irqsave(&timr->it_lock, *flags); timr 603 kernel/time/posix-timers.c if (timr->it_signal == current->signal) { timr 605 kernel/time/posix-timers.c return timr; timr 607 kernel/time/posix-timers.c spin_unlock_irqrestore(&timr->it_lock, *flags); timr 614 kernel/time/posix-timers.c static ktime_t common_hrtimer_remaining(struct k_itimer *timr, ktime_t now) timr 616 kernel/time/posix-timers.c struct hrtimer *timer = &timr->it.real.timer; timr 621 kernel/time/posix-timers.c static s64 common_hrtimer_forward(struct k_itimer *timr, ktime_t now) timr 623 kernel/time/posix-timers.c struct hrtimer *timer = &timr->it.real.timer; timr 625 kernel/time/posix-timers.c return hrtimer_forward(timer, now, timr->it_interval); timr 644 kernel/time/posix-timers.c void common_timer_get(struct k_itimer *timr, struct itimerspec64 *cur_setting) timr 646 kernel/time/posix-timers.c const struct k_clock *kc = timr->kclock; timr 651 kernel/time/posix-timers.c sig_none = timr->it_sigev_notify == SIGEV_NONE; timr 652 kernel/time/posix-timers.c iv = timr->it_interval; timr 657 kernel/time/posix-timers.c } else if (!timr->it_active) { timr 670 kernel/time/posix-timers.c kc->clock_get(timr->it_clock, &ts64); timr 677 kernel/time/posix-timers.c if (iv && (timr->it_requeue_pending & REQUEUE_PENDING || sig_none)) timr 678 kernel/time/posix-timers.c timr->it_overrun += kc->timer_forward(timr, now); timr 680 kernel/time/posix-timers.c remaining = kc->timer_remaining(timr, now); timr 697 kernel/time/posix-timers.c struct k_itimer *timr; timr 702 kernel/time/posix-timers.c timr = lock_timer(timer_id, &flags); timr 703 kernel/time/posix-timers.c if (!timr) timr 707 kernel/time/posix-timers.c kc = timr->kclock; timr 711 kernel/time/posix-timers.c kc->timer_get(timr, setting); timr 713 kernel/time/posix-timers.c unlock_timer(timr, flags); timr 759 kernel/time/posix-timers.c struct k_itimer *timr; timr 763 kernel/time/posix-timers.c timr = lock_timer(timer_id, &flags); timr 764 kernel/time/posix-timers.c if (!timr) timr 767 kernel/time/posix-timers.c overrun = timer_overrun_to_int(timr, 0); timr 768 kernel/time/posix-timers.c unlock_timer(timr, flags); timr 773 kernel/time/posix-timers.c static void common_hrtimer_arm(struct k_itimer *timr, ktime_t expires, timr 776 kernel/time/posix-timers.c struct hrtimer *timer = &timr->it.real.timer; timr 789 kernel/time/posix-timers.c if (timr->it_clock == CLOCK_REALTIME) timr 790 kernel/time/posix-timers.c timr->kclock = absolute ? &clock_realtime : &clock_monotonic; timr 792 kernel/time/posix-timers.c hrtimer_init(&timr->it.real.timer, timr->it_clock, mode); timr 793 kernel/time/posix-timers.c timr->it.real.timer.function = posix_timer_fn; timr 803 kernel/time/posix-timers.c static int common_hrtimer_try_to_cancel(struct k_itimer *timr) timr 805 kernel/time/posix-timers.c return hrtimer_try_to_cancel(&timr->it.real.timer); timr 838 kernel/time/posix-timers.c int common_timer_set(struct k_itimer *timr, int flags, timr 842 kernel/time/posix-timers.c const struct k_clock *kc = timr->kclock; timr 847 kernel/time/posix-timers.c common_timer_get(timr, old_setting); timr 850 kernel/time/posix-timers.c timr->it_interval = 0; timr 855 kernel/time/posix-timers.c if (kc->timer_try_to_cancel(timr) < 0) timr 858 kernel/time/posix-timers.c timr->it_active = 0; timr 859 kernel/time/posix-timers.c timr->it_requeue_pending = (timr->it_requeue_pending + 2) & timr 861 kernel/time/posix-timers.c timr->it_overrun_last = 0; timr 867 kernel/time/posix-timers.c timr->it_interval = timespec64_to_ktime(new_setting->it_interval); timr 869 kernel/time/posix-timers.c sigev_none = timr->it_sigev_notify == SIGEV_NONE; timr 871 kernel/time/posix-timers.c kc->timer_arm(timr, expires, flags & TIMER_ABSTIME, sigev_none); timr 872 kernel/time/posix-timers.c timr->it_active = !sigev_none; timr 881 kernel/time/posix-timers.c struct k_itimer *timr; timr 892 kernel/time/posix-timers.c timr = lock_timer(timer_id, &flags); timr 894 kernel/time/posix-timers.c if (!timr) timr 897 kernel/time/posix-timers.c kc = timr->kclock; timr 901 kernel/time/posix-timers.c error = kc->timer_set(timr, tmr_flags, new_spec64, old_spec64); timr 907 kernel/time/posix-timers.c timr = timer_wait_running(timr, &flags); timr 910 kernel/time/posix-timers.c unlock_timer(timr, flags); timr 15 kernel/time/posix-timers.h int (*timer_set)(struct k_itimer *timr, int flags, timr 18 kernel/time/posix-timers.h int (*timer_del)(struct k_itimer *timr); timr 19 kernel/time/posix-timers.h void (*timer_get)(struct k_itimer *timr, timr 21 kernel/time/posix-timers.h void (*timer_rearm)(struct k_itimer *timr); timr 22 kernel/time/posix-timers.h s64 (*timer_forward)(struct k_itimer *timr, ktime_t now); timr 23 kernel/time/posix-timers.h ktime_t (*timer_remaining)(struct k_itimer *timr, ktime_t now); timr 24 kernel/time/posix-timers.h int (*timer_try_to_cancel)(struct k_itimer *timr); timr 25 kernel/time/posix-timers.h void (*timer_arm)(struct k_itimer *timr, ktime_t expires, timr 27 kernel/time/posix-timers.h void (*timer_wait_running)(struct k_itimer *timr); timr 36 kernel/time/posix-timers.h int posix_timer_event(struct k_itimer *timr, int si_private); timr 38 kernel/time/posix-timers.h void common_timer_get(struct k_itimer *timr, struct itimerspec64 *cur_setting); timr 39 kernel/time/posix-timers.h int common_timer_set(struct k_itimer *timr, int flags,