Function report |
Source Code:kernel\cgroup\cgroup.c |
Create Date:2022-07-28 11:08:54 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:group_taskset_migrate - migrate a taskset*@mgctx: migration context* Migrate tasks in @mgctx as setup by migration preparation functions.* This function fails iff one of the ->can_attach callbacks fails and
Proto:static int cgroup_migrate_execute(struct cgroup_mgctx *mgctx)
Type:int
Parameter:
| Type | Parameter | Name |
|---|---|---|
| struct cgroup_mgctx * | mgctx |
| 2392 | tset = asks and csets to migrate |
| 2399 | If he number of tasks in the set Then |
| 2400 | Do |
| 2400 | If Not CGROUP_SUBSYS_COUNT Then |
| 2400 | ssid = 0 |
| 2400 | Break |
| 2400 | When ssid < CGROUP_SUBSYS_COUNT cycle |
| 2400 | ss = cgroup_subsys[ssid] |
| 2401 | If can_attach Then |
| 2409 | When (false) cycle |
| 2417 | spin_lock_irq( & css_set_lock) |
| 2420 | from_cset = ask_css_set - obtain a task's css_set*@task: the task to obtain css_set for* See task_css_set_check(). |
| 2421 | to_cset = mg_dst_cset |
| 2431 | cgroup_freezer_migrate_task(task, he default cgroup associated with this css_set , he default cgroup associated with this css_set ) |
| 2433 | put_css_set_locked(from_cset) |
| 2437 | spin_unlock_irq( & css_set_lock) |
| 2446 | If he number of tasks in the set Then |
| 2447 | Do |
| 2447 | If Not CGROUP_SUBSYS_COUNT Then |
| 2447 | ssid = 0 |
| 2447 | Break |
| 2447 | When ssid < CGROUP_SUBSYS_COUNT cycle |
| 2447 | ss = cgroup_subsys[ssid] |
| 2448 | If attach Then |
| 2452 | When (false) cycle |
| 2455 | ret = 0 |
| 2456 | Go to out_release_tset |
| 2458 | out_cancel_attach : |
| 2459 | If he number of tasks in the set Then |
| 2460 | Do |
| 2460 | If Not CGROUP_SUBSYS_COUNT Then |
| 2460 | ssid = 0 |
| 2460 | Break |
| 2460 | When ssid < CGROUP_SUBSYS_COUNT cycle |
| 2460 | ss = cgroup_subsys[ssid] |
| 2467 | When (false) cycle |
| 2469 | out_release_tset : |
| 2470 | spin_lock_irq( & css_set_lock) |
| 2476 | spin_unlock_irq( & css_set_lock) |
| 2483 | he number of tasks in the set = 0 |
| 2485 | Return ret |
| Name | Describe |
|---|---|
| cgroup_migrate | group_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_csses | group_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 |
| Source code conversion tool public plug-in interface | X |
|---|---|
| Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |