Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:cgroup_destroy_root

Proto:static void cgroup_destroy_root(struct cgroup_root *root)

Type:void

Parameter:

TypeParameterName
struct cgroup_root *root
1316  cgrp = The root cgroup. Root is destroyed on its release.
1319  trace_cgroup_destroy_root(root)
1321  group_lock_and_drain_offline - lock cgroup_mutex and drain offlined csses*@cgrp: root of the target subtree* Because css offlining is asynchronous, userland may try to re-enable a* controller while the previous css is still around. This function grabs
1323  BUG_ON(atomic_read( & Number of cgroups in the hierarchy, used only for /proc/cgroups ))
1324  BUG_ON(!list_empty - tests whether a list is empty*@head: the list to test.)
1327  WARN_ON(rebind_subsystems( & The default hierarchy, reserved for the subsystems that are otherwise* unattached - it never has more than a single cgroup, and all tasks are* part of that cgroup., The bitmask of subsystems attached to this hierarchy ))
1333  spin_lock_irq( & css_set_lock)
1336  deletes entry from list
1337  deletes entry from list
1338  kfree(link)
1341  spin_unlock_irq( & css_set_lock)
1343  If Not list_empty - tests whether a list is empty*@head: the list to test. Then
1344  deletes entry from list
1345  cgroup_root_count--
1348  cgroup_exit_root_id(root)
1350  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.
1352  kernfs_destroy_root(kf_root)
1353  cgroup_free_root(root)
Caller
NameDescribe
css_free_rwork_fnss destruction is four-stage process