| /kernel/linux/linux-5.10/kernel/time/ |
| D | tick-sched.h | 24 * struct tick_sched - sched tick emulation and no idle tick control/stats 25 * @sched_timer: hrtimer to schedule the periodic tick in high 29 * @inidle: Indicator that the CPU is in the tick idle mode 30 * @tick_stopped: Indicator that the idle tick has been stopped 31 * @idle_active: Indicator that the CPU is actively in the tick idle mode; 34 * @got_idle_tick: Tick timer function has run with @inidle set 35 * @last_tick: Store the last tick expiry time when the tick 37 * to resume the tick timer operation in the timeline 39 * @next_tick: Next tick to be fired when in dynticks mode. 42 * @idle_sleeps: Number of idle calls, where the sched tick was stopped [all …]
|
| D | tick-sched.c | 7 * No idle tick implementation for low and high resolution timers 31 #include "tick-internal.h" 157 * When we are idle and the tick is stopped, we have to touch in tick_sched_handle() 169 * In case the current tick fired too early past its expected in tick_sched_handle() 243 /* Empty, the tick restart happens on tick_nohz_irq_exit() */ in nohz_full_kick_func() 253 * re-evaluate its dependency on the tick and restart it if necessary. 267 * re-evaluate its dependency on the tick and restart it if necessary. 279 * their dependency on the tick and restart it if necessary. 305 * Set a global tick dependency. Used by perf events that rely on freq and 319 * Set per-CPU tick dependency. Used by scheduler and perf events in order to [all …]
|
| D | Makefile | 12 obj-$(CONFIG_GENERIC_CLOCKEVENTS) += clockevents.o tick-common.o 14 obj-y += tick-broadcast.o 15 obj-$(CONFIG_TICK_ONESHOT) += tick-broadcast-hrtimer.o 18 obj-$(CONFIG_TICK_ONESHOT) += tick-oneshot.o tick-sched.o
|
| D | tick-common.c | 3 * This file contains the base functions to manage periodic tick 23 #include "tick-internal.h" 26 * Tick devices 30 * Tick next event: keeps track of the tick time 82 * Periodic tick 90 /* Keep track of the next tick event */ in tick_periodic() 149 * Setup the device for a periodic tick 202 * Setup the tick device 450 * tick_suspend_local - Suspend the local tick device 464 * tick_resume_local - Resume the local tick device [all …]
|
| /kernel/linux/linux-4.19/kernel/time/ |
| D | tick-sched.h | 24 * struct tick_sched - sched tick emulation and no idle tick control/stats 25 * @sched_timer: hrtimer to schedule the periodic tick in high 27 * @last_tick: Store the last tick expiry time when the tick 29 * to resume the tick timer operation in the timeline 31 * @next_tick: Next tick to be fired when in dynticks mode. 32 * @tick_stopped: Indicator that the idle tick has been stopped 35 * @idle_sleeps: Number of idle calls, where the sched tick was stopped 39 * @idle_sleeptime: Sum of the time slept in idle with sched tick stopped 40 * @iowait_sleeptime: Sum of the time slept in idle with sched tick stopped, with IO outstanding 41 * @timer_expires: Anticipated timer expiration time (in case sched tick is stopped) [all …]
|
| D | tick-sched.c | 2 * linux/kernel/time/tick-sched.c 8 * No idle tick implementation for low and high resolution timers 34 #include "tick-internal.h" 149 * When we are idle and the tick is stopped, we have to touch in tick_sched_handle() 161 * In case the current tick fired too early past its expected in tick_sched_handle() 229 /* Empty, the tick restart happens on tick_nohz_irq_exit() */ in nohz_full_kick_func() 238 * re-evaluate its dependency on the tick and restart it if necessary. 252 * re-evaluate its dependency on the tick and restart it if necessary. 264 * their dependency on the tick and restart it if necessary. 290 * Set a global tick dependency. Used by perf events that rely on freq and [all …]
|
| D | tick-common.c | 2 * linux/kernel/time/tick-common.c 4 * This file contains the base functions to manage periodic tick 26 #include "tick-internal.h" 29 * Tick devices 33 * Tick next event: keeps track of the tick time 77 * Periodic tick 84 /* Keep track of the next tick event */ in tick_periodic() 142 * Setup the device for a periodic tick 175 * Setup the tick device 409 * tick_suspend_local - Suspend the local tick device [all …]
|
| D | Makefile | 12 obj-$(CONFIG_GENERIC_CLOCKEVENTS) += clockevents.o tick-common.o 14 obj-y += tick-broadcast.o 15 obj-$(CONFIG_TICK_ONESHOT) += tick-broadcast-hrtimer.o 18 obj-$(CONFIG_TICK_ONESHOT) += tick-oneshot.o tick-sched.o
|
| /kernel/linux/linux-5.10/sound/core/seq/ |
| D | seq_timer.h | 13 snd_seq_tick_time_t cur_tick; /* current tick */ 14 unsigned long resolution; /* time per tick in nsec */ 15 unsigned long fraction; /* current time per tick in nsec */ 24 unsigned int tempo; /* current tempo, us/tick */ 28 struct snd_seq_timer_tick tick; /* current tick */ member 53 static inline void snd_seq_timer_update_tick(struct snd_seq_timer_tick *tick, in snd_seq_timer_update_tick() argument 56 if (tick->resolution > 0) { in snd_seq_timer_update_tick() 57 tick->fraction += resolution; in snd_seq_timer_update_tick() 58 tick->cur_tick += (unsigned int)(tick->fraction / tick->resolution); in snd_seq_timer_update_tick() 59 tick->fraction %= tick->resolution; in snd_seq_timer_update_tick()
|
| /kernel/linux/linux-4.19/sound/core/seq/ |
| D | seq_timer.h | 28 snd_seq_tick_time_t cur_tick; /* current tick */ 29 unsigned long resolution; /* time per tick in nsec */ 30 unsigned long fraction; /* current time per tick in nsec */ 39 unsigned int tempo; /* current tempo, us/tick */ 43 struct snd_seq_timer_tick tick; /* current tick */ member 68 static inline void snd_seq_timer_update_tick(struct snd_seq_timer_tick *tick, in snd_seq_timer_update_tick() argument 71 if (tick->resolution > 0) { in snd_seq_timer_update_tick() 72 tick->fraction += resolution; in snd_seq_timer_update_tick() 73 tick->cur_tick += (unsigned int)(tick->fraction / tick->resolution); in snd_seq_timer_update_tick() 74 tick->fraction %= tick->resolution; in snd_seq_timer_update_tick()
|
| /kernel/liteos_m/testsuites/sample/kernel/swtmr/ |
| D | It_los_swtmr_072.c | 48 UINT32 tick = 0; in Testcase() local 62 ret = LOS_SwtmrTimeGet(g_swtmrId1, &tick); in Testcase() 78 ret = LOS_SwtmrTimeGet(g_swtmrId1, &tick); in Testcase() 80 ICUNIT_GOTO_EQUAL(tick, TIMER_LOS_EXPIRATION3 - delayTime - 1, tick, EXIT); in Testcase() 85 ret = LOS_SwtmrTimeGet(g_swtmrId1, &tick); in Testcase() 95 ret = LOS_SwtmrTimeGet(g_swtmrId1, &tick); in Testcase() 97 ICUNIT_GOTO_EQUAL(tick, TIMER_LOS_EXPIRATION3 - 1, tick, EXIT); in Testcase() 102 ret = LOS_SwtmrTimeGet(g_swtmrId1, &tick); in Testcase()
|
| D | It_los_swtmr_069.c | 39 UINT32 tick = 0; in SwtmrF01() local 45 ret = LOS_SwtmrTimeGet(g_swtmrId1, &tick); in SwtmrF01() 47 ICUNIT_GOTO_EQUAL(tick, TIMER_LOS_EXPIRATION1 - 1, tick, EXIT); in SwtmrF01() 59 UINT32 tick = 0; in Testcase() local 79 ret = LOS_SwtmrTimeGet(g_swtmrId1, &tick); in Testcase() 83 ICUNIT_GOTO_EQUAL(tick, 1, tick, EXIT); in Testcase() 91 ret = LOS_SwtmrTimeGet(g_swtmrId1, &tick); in Testcase()
|
| D | It_los_swtmr_068.c | 50 UINT32 tick = 0; in Testcase() local 66 ret = LOS_SwtmrTimeGet(swTmrID, &tick); in Testcase() 68 ICUNIT_GOTO_EQUAL(tick, TIMER_LOS_EXPIRATION1 - 1, tick, EXIT); in Testcase() 73 ret = LOS_SwtmrTimeGet(swTmrID, &tick); in Testcase() 76 ICUNIT_GOTO_EQUAL(tick, 1, tick, EXIT); in Testcase() 84 ret = LOS_SwtmrTimeGet(swTmrID, &tick); in Testcase()
|
| D | It_los_swtmr_071.c | 48 UINT32 tick = 0; in Testcase() local 62 ret = LOS_SwtmrTimeGet(g_swtmrId1, &tick); in Testcase() 78 ret = LOS_SwtmrTimeGet(g_swtmrId1, &tick); in Testcase() 80 ICUNIT_GOTO_EQUAL(tick, TIMER_LOS_EXPIRATION3 - delayTime - 1, tick, EXIT); in Testcase() 85 ret = LOS_SwtmrTimeGet(g_swtmrId1, &tick); in Testcase() 98 ret = LOS_SwtmrTimeGet(g_swtmrId1, &tick); in Testcase()
|
| /kernel/linux/linux-5.10/tools/testing/selftests/timers/ |
| D | adjtick.c | 1 /* adjtimex() tick adjustment test 128 tx1.tick = tickval; in check_tick_adj() 135 printf("Estimating tick (act: %ld usec, %lld ppm): ", tickval, ppm); in check_tick_adj() 144 if (tx1.offset || tx1.freq || tx1.tick != tickval) { in check_tick_adj() 153 * cannot match the HZ tick size accurately, so we have a in check_tick_adj() 171 long tick, max, interval, err; in main() local 189 for (tick = (systick - max); tick < (systick + max); tick += interval) { in main() 190 if (check_tick_adj(tick)) { in main() 203 tx1.tick = systick; in main()
|
| /kernel/linux/linux-4.19/tools/testing/selftests/timers/ |
| D | adjtick.c | 1 /* adjtimex() tick adjustment test 128 tx1.tick = tickval; in check_tick_adj() 135 printf("Estimating tick (act: %ld usec, %lld ppm): ", tickval, ppm); in check_tick_adj() 144 if (tx1.offset || tx1.freq || tx1.tick != tickval) { in check_tick_adj() 153 * cannot match the HZ tick size accurately, so we have a in check_tick_adj() 171 long tick, max, interval, err; in main() local 189 for (tick = (systick - max); tick < (systick + max); tick += interval) { in main() 190 if (check_tick_adj(tick)) { in main() 203 tx1.tick = systick; in main()
|
| /kernel/liteos_a/compat/posix/include/ |
| D | time_posix.h | 70 UINT64 tick, ns; in OsTimeSpec2Tick() local 74 …tick = (ns * LOSCFG_BASE_CORE_TICK_PER_SECOND + (OS_SYS_NS_PER_SECOND - 1)) / OS_SYS_NS_PER_SECOND; in OsTimeSpec2Tick() 75 if (tick > LOS_WAIT_FOREVER) { in OsTimeSpec2Tick() 76 tick = LOS_WAIT_FOREVER; in OsTimeSpec2Tick() 78 return (UINT32)tick; in OsTimeSpec2Tick() 81 STATIC INLINE VOID OsTick2TimeSpec(struct timespec *tp, UINT32 tick) in OsTick2TimeSpec() argument 83 UINT64 ns = ((UINT64)tick * OS_SYS_NS_PER_SECOND) / LOSCFG_BASE_CORE_TICK_PER_SECOND; in OsTick2TimeSpec()
|
| /kernel/linux/linux-5.10/Documentation/timers/ |
| D | highres.rst | 100 System-level global event devices are used for the Linux periodic tick. Per-CPU 107 - system global periodic tick (jiffies update) 132 utilize the high resolution and dynamic tick functionalities without any change 136 adding the dynamic tick specific calls to the idle routine (a total of 3 lines 186 Once a system has switched to high resolution mode, the periodic tick is 190 The periodic tick functionality is provided by an per-cpu hrtimer. The callback 193 based periodic tick is designed to be extended with dynamic tick functionality. 195 timer and periodic events (jiffies tick, profiling, process accounting) on UP 200 separated from the tick bound timer softirq to allow accurate delivery of high 211 Dynamic ticks are the logical consequence of the hrtimer based periodic tick [all …]
|
| /kernel/linux/linux-4.19/Documentation/timers/ |
| D | highres.txt | 97 System-level global event devices are used for the Linux periodic tick. Per-CPU 103 - system global periodic tick (jiffies update) 128 utilize the high resolution and dynamic tick functionalities without any change 132 adding the dynamic tick specific calls to the idle routine (a total of 3 lines 182 Once a system has switched to high resolution mode, the periodic tick is 186 The periodic tick functionality is provided by an per-cpu hrtimer. The callback 189 based periodic tick is designed to be extended with dynamic tick functionality. 191 timer and periodic events (jiffies tick, profiling, process accounting) on UP 196 separated from the tick bound timer softirq to allow accurate delivery of high 207 Dynamic ticks are the logical consequence of the hrtimer based periodic tick [all …]
|
| /kernel/linux/linux-5.10/Documentation/admin-guide/pm/ |
| D | cpuidle.rst | 165 tick can be `stopped by the idle loop <idle-cpus-and-tick_>`_. Available 186 .. _idle-cpus-and-tick: 188 Idle CPUs and The Scheduler Tick 191 The scheduler tick is a timer that triggers periodically in order to implement 199 may not want to give the CPU away voluntarily, however, and the scheduler tick 201 tick, but it is the primary reason for using it. 203 The scheduler tick is problematic from the CPU idle time management perspective, 205 configuration, the length of the tick period is between 1 ms and 10 ms). 206 Thus, if the tick is allowed to trigger on idle CPUs, it will not make sense 208 the tick period length. Moreover, in that case the idle duration of any CPU [all …]
|
| /kernel/liteos_m/kal/posix/src/ |
| D | signal.c | 43 unsigned long long tick, ns; in TimeSpec2Tick() local 47 …tick = (ns * LOSCFG_BASE_CORE_TICK_PER_SECOND + (OS_SYS_NS_PER_SECOND - 1)) / OS_SYS_NS_PER_SECOND; in TimeSpec2Tick() 48 if (tick > LOS_WAIT_FOREVER) { in TimeSpec2Tick() 49 tick = LOS_WAIT_FOREVER; in TimeSpec2Tick() 51 return (unsigned int)tick; in TimeSpec2Tick() 129 int tick = LOS_WAIT_FOREVER; in sigtimedwait() local 133 tick = TimeSpec2Tick(timeout); in sigtimedwait() 136 ret = LOS_SignalWait(set, info, tick); in sigtimedwait()
|
| /kernel/liteos_m/kernel/src/ |
| D | los_tick.c | 114 STATIC UINT32 TickTimerCheck(const ArchTickTimer *tick) in TickTimerCheck() argument 116 if (tick == NULL) { in TickTimerCheck() 120 if ((tick->freq == 0) || in TickTimerCheck() 122 (LOSCFG_BASE_CORE_TICK_PER_SECOND > tick->freq)) { in TickTimerCheck() 126 if (tick->irqNum > (INT32)LOSCFG_PLATFORM_HWI_LIMIT) { in TickTimerCheck() 130 if (tick->periodMax == 0) { in TickTimerCheck() 134 if ((tick->init == NULL) || (tick->reload == NULL) || in TickTimerCheck() 135 (tick->lock == NULL) || (tick->unlock == NULL) || in TickTimerCheck() 136 (tick->getCycle == NULL)) { in TickTimerCheck() 245 Description : get current tick [all …]
|
| /kernel/liteos_m/kernel/include/ |
| D | los_tick.h | 51 * Tick error code: The Tick configuration is incorrect. 62 * Tick error code: The system tick timer uninitialized. 72 * Tick error code: The number of Ticks is too small. 122 * Cycles per Tick 216 * System time error code: The Tick Timer must be registered before kernel initialization. 226 * System time error code: The tick timer method is NULL. 236 * System time error code: The tick timer addr fault. 352 * @brief Re-initializes the system tick timer. 355 * This API is used to re-initialize the system Tick timer. 358 * @param timer [IN] Specify the tick timer. [all …]
|
| /kernel/linux/linux-5.10/arch/sparc/include/asm/ |
| D | timer_64.h | 48 unsigned int tick[GET_TICK_NINSTR]; member 57 unsigned long tick, tmp1, tmp2; in get_tick() local 81 /* read tick 2 instructions and 11 skipped */ in get_tick() 83 " rd %%tick, %0\n" in get_tick() 93 : "=&r" (tick), "=&r" (tmp1), "=&r" (tmp2) in get_tick() 96 return tick; in get_tick()
|
| /kernel/linux/linux-4.19/arch/sparc/include/asm/ |
| D | timer_64.h | 47 unsigned int tick[GET_TICK_NINSTR]; member 56 unsigned long tick, tmp1, tmp2; in get_tick() local 80 /* read tick 2 instructions and 11 skipped */ in get_tick() 82 " rd %%tick, %0\n" in get_tick() 92 : "=&r" (tick), "=&r" (tmp1), "=&r" (tmp2) in get_tick() 95 return tick; in get_tick()
|