函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\time\hrtimer.c Create Date:2022-07-27 11:40:48
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:A timer is active, when it is enqueued into the rbtree or the* callback function is running or it's in the state of being migrated* to another cpu.* It is important for this function to not return a false negative.

函数原型:bool hrtimer_active(const struct hrtimer *timer)

返回类型:bool

参数:

类型参数名称
const struct hrtimer *timer
1444  循环
1445  base等于READ_ONCE(base)
1446  seq等于aw_read_seqcount_begin - start seq-read critical section w/o lockdep*@s: pointer to seqcount_t* Returns: count to be passed to read_seqcount_retry* raw_read_seqcount_begin opens a read critical section of the given
1448  如果state不等于Values to track state of the timer* Possible states:* 0x00 inactive* 0x01 enqueued into rbtree* The callback state is not part of the timer->state because clearing it would* mean touching the timer after the callback, this makes it impossible to freerunning恒等于timer则返回:true
1452 ad_seqcount_retry - end a seq-read critical section*@s: pointer to seqcount_t*@start: count, from read_seqcount_begin* Returns: 1 if retry is required, else 0* read_seqcount_retry closes a read critical section of the given seqcountbase不等于READ_ONCE(base)循环
1455  返回:false
调用者
名称描述
task_non_contendingThe utilization of a task cannot be immediately removed from* the rq active utilization (running_bw) when the task blocks
sched_dl_overflowWe must be sure that accepting a new task (or allowing changing the* parameters of an existing one) is consistent with the bandwidth* constraints. If yes, this function also accordingly updates the currently
hrtimer_try_to_cancelhrtimer_try_to_cancel - try to deactivate a timer*@timer: hrtimer to stop* Returns:* * 0 when the timer was not active* * 1 when the timer was active* * -1 when the timer is currently executing the callback function and* cannot be stopped
itimer_get_remtimemer_get_remtime - get remaining time for the timer*@timer: the timer to read* Returns the delta between the expiry time and now, which can be* less than zero or 1usec for an pending expired timer
sched_rt_bandwidth_account