函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:alled on fork with the child task as argument from the parent's context* - child not yet on the tasklist* - preemption disabled

函数原型:static void task_fork_fair(struct task_struct *p)

返回类型:void

参数:

类型参数名称
struct task_struct *p
10301  se等于调度实体
10302  rq等于this_rq()
10305  rq_lock(rq, & rf)
10306  更新rq运行时间
10308  cfs_rq等于task_cfs_rq(当前进程)
10309  curr等于'curr' points to currently running entity on this cfs_rq.* It is set to NULL otherwise (i.e when none are currently running).
10310  如果curr
10311  更新当前进程运行时间,包括虚拟运行时间
10312  vruntime等于vruntime
10314  place_entity(cfs_rq, se, 1)
10316  如果After fork, child runs first. If set to 0 (default) then* parent will (try to) run first.currentity_before(curr, se)则
10321  swap - swap values of @a and @b*@a: first value*@b: second value(vruntime, vruntime)
10322  标记当前进程需要被调度出去
10325  vruntime减等于min_vruntime
10326  rq_unlock(rq, & rf)