Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:d the appropriate pidlist for our purpose (given procs vs tasks)* returns with the lock on that pidlist already held, and takes care* of the use count, or returns NULL with no locks held if we're out of* memory.

Proto:static struct cgroup_pidlist *cgroup_pidlist_find_create(struct cgroup *cgrp, enum cgroup_filetype type)

Type:struct cgroup_pidlist

Parameter:

TypeParameterName
struct cgroup *cgrp
enum cgroup_filetypetype
307  lockdep_assert_held( & pidlist_mutex)
309  l = cgroup_pidlist_find(cgrp, type)
310  If l Then Return l
314  l = kzalloc - allocate memory. The memory is set to zero.*@size: how many bytes of memory are required.*@flags: the type of memory to allocate (see kmalloc).
315  If Not l Then Return l
318  INIT_DELAYED_WORK( & r delayed destruction , cgroup_pidlist_destroy_work_fn)
319  type = type
321  ns = get_pid_ns(task_active_pid_ns(current process))
322  pointer to the cgroup we belong to, for list removal purposes = cgrp
323  list_add - add a new entry*@new: new entry to be added*@head: list head to add it after* Insert a new entry after the specified head.* This is good for implementing stacks.
324  Return l
Caller
NameDescribe
pidlist_array_loadLoad a cgroup's pidarray with either procs' tgids or tasks' pids