函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:group_taskset_next - iterate to the next task in taskset*@tset: taskset of interest*@dst_cssp: output variable for the destination css* Return the next task in @tset. Iteration must have been initialized* with cgroup_taskset_first().

函数原型:struct task_struct *cgroup_taskset_next(struct cgroup_taskset *tset, struct cgroup_subsys_state **dst_cssp)

返回类型:struct task_struct

参数:

类型参数名称
struct cgroup_taskset *tset
struct cgroup_subsys_state **dst_cssp
2346  cset等于cur_cset
2347  task等于cur_task
2349 mg_node不等于Fields for cgroup_taskset_*() iteration.* Before migration is committed, the target migration tasks are on* ->mg_tasks of the csets on ->src_csets. After, on ->mg_tasks of* the csets on ->dst_csets. ->csets point to either ->src_csets循环
2350  如果非tasktask等于list_first_entry - get the first element from a list*@ptr: the list head to take the element from.*@type: the type of the struct this is embedded in.*@member: the name of the list_head within the struct.* Note, that list is expected to be not empty.( & mg_tasks, structtask_struct, cg_list)
2353  否则task等于list_next_entry - get the next element in list*@pos: the type * to cursor*@member: the name of the list_head within the struct.(task, cg_list)
2357  cur_cset等于cset
2358  cur_task等于task
2371  返回:task
2374  cset等于list_next_entry - get the next element in list*@pos: the type * to cursor*@member: the name of the list_head within the struct.(cset, mg_node)
2375  task = NULL
2378  返回:NULL
调用者
名称描述
cgroup_taskset_firstgroup_taskset_first - reset taskset and return the first task*@tset: taskset of interest*@dst_cssp: output variable for the destination css*@tset iteration is initialized and the first task is returned.