Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:group_add_cftypes - add an array of cftypes to a subsystem*@ss: target cgroup subsystem*@cfts: zero-length name terminated array of cftypes* Register @cfts to @ss

Proto:static int cgroup_add_cftypes(struct cgroup_subsys *ss, struct cftype *cfts)

Type:int

Parameter:

TypeParameterName
struct cgroup_subsys *ss
struct cftype *cfts
4027  If Not group_ssid_enabled - cgroup subsys enabled test by subsys ID*@ssid: subsys ID of interest* cgroup_subsys_enabled() can only be used with literal subsys names which* is fine for individual subsystems but unsuitable for cgroup core. This Then Return 0
4030  If Not cfts || 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' Then Return 0
4033  ret = cgroup_init_cftypes(ss, cfts)
4034  If ret Then Return ret
4037  mutex_lock( & cgroup_mutex is the master lock)
4039  list_add_tail - add a new entry*@new: new entry to be added*@head: list head to add it before* Insert a new entry before the specified head.* This is useful for implementing queues.
4040  ret = cgroup_apply_cftypes(cfts, true)
4041  If ret Then cgroup_rm_cftypes_locked(cfts)
4044  mutex_unlock - release the mutex*@lock: the mutex to be released* Unlock a mutex that has been locked by this task previously.* This function must not be used in interrupt context. Unlocking* of a not locked mutex is not allowed.
4045  Return ret
Caller
NameDescribe
cgroup_add_dfl_cftypesgroup_add_dfl_cftypes - add an array of cftypes for default hierarchy*@ss: target cgroup subsystem*@cfts: zero-length name terminated array of cftypes* Similar to cgroup_add_cftypes() but the added files are only used for* the default hierarchy.
cgroup_add_legacy_cftypesgroup_add_legacy_cftypes - add an array of cftypes for legacy hierarchies*@ss: target cgroup subsystem*@cfts: zero-length name terminated array of cftypes* Similar to cgroup_add_cftypes() but the added files are only used for* the legacy hierarchies.
cgroup_initgroup_init - cgroup initialization* Register cgroup filesystem and /proc file, and initialize* any subsystems that didn't request early init.