Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\sched\rt.c Create Date:2022-07-28 09:39:18
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Update the current task's runtime statistics. Skip current tasks that* are not in our scheduling class.

Proto:static void update_curr_rt(struct rq *rq)

Type:void

Parameter:

TypeParameterName
struct rq *rq
957  curr = curr
958  rt_se = rt
962  If sched_class != rt_sched_class Then Return
965  now = rq_clock_task(rq)
966  delta_exec = now - exec_start
967  If Value for the false possibility is greater at compile time((s64)delta_exec <= 0) Then Return
970  schedstat_set(exec_max, max - return maximum of two values of the same or compatible types*@x: first value*@y: second value(exec_max, delta_exec))
973  sum_exec_runtime += delta_exec
974  account_group_exec_runtime - Maintain exec runtime for a thread group
976  exec_start = now
977  cgroup_account_cputime(curr, delta_exec)
979  If Not rt_bandwidth_enabled() Then Return
983  rt_rq = rt_rq_of_se(rt_se)
985  If sched_rt_runtime(rt_rq) != Single value that denotes runtime == period, ie unlimited time. Then
986  raw_spin_lock( & Nests inside the rq lock: )
987  rt_time += delta_exec
988  If sched_rt_runtime_exceeded(rt_rq) Then sched_curr - mark rq's current task 'to be rescheduled now'.* On UP this means the setting of the need_resched flag, on SMP it* might also involve a cross-CPU call to trigger the scheduler on* the target CPU.
990  raw_spin_unlock( & Nests inside the rq lock: )
Caller
NameDescribe
dequeue_task_rt
put_prev_task_rt
task_tick_rtscheduler tick hitting a task of our scheduling class