From 61c41711b12b808ec388b739444372430942c2e8 Mon Sep 17 00:00:00 2001 From: William Dean Date: Sat, 17 Sep 2022 16:40:39 +0800 Subject: cgroup: simplify code in cgroup_apply_control It could directly return 'cgroup_update_dfl_csses' to simplify code. Signed-off-by: William Dean Reviewed-by: Mukesh Ojha Signed-off-by: Tejun Heo --- kernel/cgroup/cgroup.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'kernel/cgroup') diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c index c1f1ef6090da..c37b8265c0a3 100644 --- a/kernel/cgroup/cgroup.c +++ b/kernel/cgroup/cgroup.c @@ -3305,11 +3305,7 @@ static int cgroup_apply_control(struct cgroup *cgrp) * making the following cgroup_update_dfl_csses() properly update * css associations of all tasks in the subtree. */ - ret = cgroup_update_dfl_csses(cgrp); - if (ret) - return ret; - - return 0; + return cgroup_update_dfl_csses(cgrp); } /** -- cgit v1.2.3