projects
/
GitHub
/
LineageOS
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5a621e6
)
cgroup: short-circuit cset_cgroup_from_root() on the default hierarchy
author
Tejun Heo
<tj@kernel.org>
Wed, 2 Aug 2017 22:39:38 +0000
(15:39 -0700)
committer
Tejun Heo
<tj@kernel.org>
Wed, 2 Aug 2017 22:39:38 +0000
(15:39 -0700)
Each css_set directly points to the default cgroup it belongs to, so
there's no reason to walk the cgrp_links list on the default
hierarchy.
Signed-off-by: Tejun Heo <tj@kernel.org>
kernel/cgroup/cgroup.c
patch
|
blob
|
blame
|
history
diff --git
a/kernel/cgroup/cgroup.c
b/kernel/cgroup/cgroup.c
index 92e59979622089daa80280e18608c531f7b16cb7..f5ca55db1fe15a5a8f6dd578a19e5c65c5069358 100644
(file)
--- a/
kernel/cgroup/cgroup.c
+++ b/
kernel/cgroup/cgroup.c
@@
-1311,6
+1311,8
@@
static struct cgroup *cset_cgroup_from_root(struct css_set *cset,
if (cset == &init_css_set) {
res = &root->cgrp;
+ } else if (root == &cgrp_dfl_root) {
+ res = cset->dfl_cgrp;
} else {
struct cgrp_cset_link *link;