Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:cgroup_addrm_files

Proto:static int cgroup_addrm_files(struct cgroup_subsys_state *css, struct cgroup *cgrp, struct cftype cfts[], bool is_add)

Type:int

Parameter:

TypeParameterName
struct cgroup_subsys_state *css
struct cgroup *cgrp
struct cftypecfts
boolis_add
3865  struct cftype * cft, * cft_end = NULL
3866  ret = 0
3868  lockdep_assert_held( & cgroup_mutex is the master lock)
3870  restart :
3871  When cft != cft_end && By convention, the name should begin with the name of the* subsystem, followed by a period. Zero length string indicates* end of cftype array.[0] != '\0' cycle
3873  If CFTYPE_* flags & __CFTYPE_ONLY_ON_DFL && Not group_on_dfl - test whether a cgroup is on the default hierarchy*@cgrp: the cgroup of interest* The default hierarchy is the v2 interface of cgroup and this function* can be used to test whether a cgroup is on the default hierarchy for* cases where a Then Continue
3875  If CFTYPE_* flags & __CFTYPE_NOT_ON_DFL && group_on_dfl - test whether a cgroup is on the default hierarchy*@cgrp: the cgroup of interest* The default hierarchy is the v2 interface of cgroup and this function* can be used to test whether a cgroup is on the default hierarchy for* cases where a Then Continue
3877  If CFTYPE_* flags & CFTYPE_NOT_ON_ROOT && Not cgroup_parent(cgrp) Then Continue
3879  If CFTYPE_* flags & CFTYPE_ONLY_ON_ROOT && cgroup_parent(cgrp) Then Continue
3881  If CFTYPE_* flags & CFTYPE_DEBUG && Not cgroup_debug Then Continue
3883  If is_add Then
3885  If ret Then
3892  Else
3896  Return ret
Caller
NameDescribe
css_clear_dirss_clear_dir - remove subsys files in a cgroup directory*@css: taget css
css_populate_dirss_populate_dir - create subsys files in a cgroup directory*@css: target css* On failure, no file is added.
cgroup_apply_cftypes