函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:__hrtimer_next_event_base

函数原型:static ktime_t __hrtimer_next_event_base(struct hrtimer_cpu_base *cpu_base, const struct hrtimer *exclude, unsigned int active, ktime_t expires_next)

返回类型:ktime_t

参数:

类型参数名称
struct hrtimer_cpu_base *cpu_base
const struct hrtimer *exclude
unsigned intactive
ktime_texpires_next
515  next等于返回计时器的最早的过期时间
516  timer等于container_of - cast a member of a structure out to the containing structure*@ptr: the pointer to the member.*@type: the type of the container struct this is embedded in.*@member: the name of the member within the struct.(next, structhrtimer, node)
517  如果timer恒等于exclude
519  next等于merqueue_iterate_next - Returns the timer after the provided timer*@node: Pointer to a timer.* Provides the timer that is after the given node. This is used, when* necessary, to iterate through the list of timers in a timer list
520  如果非next则继续下一循环
523  timer等于container_of - cast a member of a structure out to the containing structure*@ptr: the pointer to the member.*@type: the type of the container struct this is embedded in.*@member: the name of the member within the struct.(next, structhrtimer, node)
525  expires等于Subtract two ktime_t variables. rem = lhs -rhs: (hrtimer_get_expires(timer), offset)
526  如果expires小于expires_next
527  expires_next等于expires
530  如果exclude则继续下一循环
533  如果is_softsoftirq_next_timer等于timer
535  否则next_timer等于timer
544  如果expires_next小于0则expires_next等于0
546  返回:expires_next
调用者
名称描述
__hrtimer_get_next_eventRecomputes cpu_base::*next_timer and returns the earliest expires_next but* does not set cpu_base::*expires_next, that is done by hrtimer_reprogram