Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\time\hrtimer.c Create Date:2022-07-28 10:40:36
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:__hrtimer_next_event_base

Proto:static ktime_t __hrtimer_next_event_base(struct hrtimer_cpu_base *cpu_base, const struct hrtimer *exclude, unsigned int active, ktime_t expires_next)

Type:ktime_t

Parameter:

TypeParameterName
struct hrtimer_cpu_base *cpu_base
const struct hrtimer *exclude
unsigned intactive
ktime_texpires_next
515  next = merqueue_getnext - Returns the timer with the earliest expiration time*@head: head of timerqueue* Returns a pointer to the timer node that has the earliest expiration time.
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  If timer == exclude Then
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  If Not next Then Continue
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  If expires < expires_next Then
527  expires_next = expires
530  If exclude Then Continue
533  If is_soft Then softirq_next_timer = timer
535  Else next_timer = timer
544  If expires_next < 0 Then expires_next = 0
546  Return expires_next
Caller
NameDescribe
__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