函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:group_migrate_add_task - add a migration target task to a migration context*@task: target task*@mgctx: target migration context* Add @task, which is a migration target, to @mgctx->tset. This function* becomes noop if @task doesn't need to be migrated

函数原型:static void cgroup_migrate_add_task(struct task_struct *task, struct cgroup_mgctx *mgctx)

返回类型:void

参数:

类型参数名称
struct task_struct *task
struct cgroup_mgctx *mgctx
2295  lockdep_assert_held( & css_set_lock)
2298  如果任务标志按位与Getting shut down 则返回
2302  WARN_ON_ONCE(链表为空)
2304  cset等于获得任务的css_set
2305  如果非If this cset is acting as the source of migration the following* two fields are set. mg_src_cgrp and mg_dst_cgrp are* respectively the source and destination cgroups of the on-going* migration. mg_dst_cset is the destination cset the target tasks则返回
2308  he number of tasks in the set 自加
2310  链表项移动到尾部
2311  如果链表为空添加链表项
2314  如果链表为空添加链表项
调用者
名称描述
cgroup_migrategroup_migrate - migrate a process or task to a cgroup*@leader: the leader of the process or the task to migrate*@threadgroup: whether @leader points to the whole process or a single task*@mgctx: migration context
cgroup_update_dfl_cssesgroup_update_dfl_csses - update css assoc of a subtree in default hierarchy*@cgrp: root of the subtree to update csses for*@cgrp's control masks have changed and its subtree's css associations* need to be updated accordingly