All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH -next] cgroup: simplify code in cgroup_apply_control
@ 2022-09-17  8:40 ` williamsukatube-9Onoh4P/yGk
  0 siblings, 0 replies; 6+ messages in thread
From: williamsukatube @ 2022-09-17  8:40 UTC (permalink / raw)
  To: tj, lizefan.x, hannes, cgroups, linux-kernel; +Cc: William Dean

From: William Dean <williamsukatube@163.com>

It could directly return 'cgroup_update_dfl_csses' to simplify code.

Signed-off-by: William Dean <williamsukatube@163.com>
---
 kernel/cgroup/cgroup.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c
index e4bb5d57f4d1..1958f8bd93d6 100644
--- a/kernel/cgroup/cgroup.c
+++ b/kernel/cgroup/cgroup.c
@@ -3292,11 +3292,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);
 }

 /**
--
2.25.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH -next] cgroup: simplify code in cgroup_apply_control
@ 2022-09-17  8:40 ` williamsukatube-9Onoh4P/yGk
  0 siblings, 0 replies; 6+ messages in thread
From: williamsukatube-9Onoh4P/yGk @ 2022-09-17  8:40 UTC (permalink / raw)
  To: tj-DgEjT+Ai2ygdnm+yROfE0A, lizefan.x-EC8Uxl6Npydl57MIdRCFDg,
	hannes-druUgvl0LCNAfugRpC6u6w, cgroups-u79uwXL29TY76Z2rM5mHXA,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA
  Cc: William Dean

From: William Dean <williamsukatube-9Onoh4P/yGk@public.gmane.org>

It could directly return 'cgroup_update_dfl_csses' to simplify code.

Signed-off-by: William Dean <williamsukatube-9Onoh4P/yGk@public.gmane.org>
---
 kernel/cgroup/cgroup.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c
index e4bb5d57f4d1..1958f8bd93d6 100644
--- a/kernel/cgroup/cgroup.c
+++ b/kernel/cgroup/cgroup.c
@@ -3292,11 +3292,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);
 }

 /**

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH -next] cgroup: simplify code in cgroup_apply_control
  2022-09-17  8:40 ` williamsukatube-9Onoh4P/yGk
@ 2022-09-19 10:49   ` Mukesh Ojha
  -1 siblings, 0 replies; 6+ messages in thread
From: Mukesh Ojha @ 2022-09-19 10:49 UTC (permalink / raw)
  To: williamsukatube, tj, lizefan.x, hannes, cgroups, linux-kernel

Hi,

On 9/17/2022 2:10 PM, williamsukatube@163.com wrote:
> From: William Dean <williamsukatube@163.com>
> 
> It could directly return 'cgroup_update_dfl_csses' to simplify code.
> 
> Signed-off-by: William Dean <williamsukatube@163.com>
> ---
>   kernel/cgroup/cgroup.c | 6 +-----
>   1 file changed, 1 insertion(+), 5 deletions(-)
> 
> diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c
> index e4bb5d57f4d1..1958f8bd93d6 100644
> --- a/kernel/cgroup/cgroup.c
> +++ b/kernel/cgroup/cgroup.c
> @@ -3292,11 +3292,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);
>   }
> 
>   /**
> --
> 2.25.1
> 

LGTM.

Reviewed-by: Mukesh Ojha <quic_mojha@quicinc.com>

-Mukesh

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH -next] cgroup: simplify code in cgroup_apply_control
@ 2022-09-19 10:49   ` Mukesh Ojha
  0 siblings, 0 replies; 6+ messages in thread
From: Mukesh Ojha @ 2022-09-19 10:49 UTC (permalink / raw)
  To: williamsukatube, tj, lizefan.x, hannes, cgroups, linux-kernel

Hi,

On 9/17/2022 2:10 PM, williamsukatube@163.com wrote:
> From: William Dean <williamsukatube@163.com>
> 
> It could directly return 'cgroup_update_dfl_csses' to simplify code.
> 
> Signed-off-by: William Dean <williamsukatube@163.com>
> ---
>   kernel/cgroup/cgroup.c | 6 +-----
>   1 file changed, 1 insertion(+), 5 deletions(-)
> 
> diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c
> index e4bb5d57f4d1..1958f8bd93d6 100644
> --- a/kernel/cgroup/cgroup.c
> +++ b/kernel/cgroup/cgroup.c
> @@ -3292,11 +3292,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);
>   }
> 
>   /**
> --
> 2.25.1
> 

LGTM.

Reviewed-by: Mukesh Ojha <quic_mojha@quicinc.com>

-Mukesh

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH -next] cgroup: simplify code in cgroup_apply_control
@ 2022-09-24  2:52   ` Tejun Heo
  0 siblings, 0 replies; 6+ messages in thread
From: Tejun Heo @ 2022-09-24  2:52 UTC (permalink / raw)
  To: williamsukatube; +Cc: lizefan.x, hannes, cgroups, linux-kernel

On Sat, Sep 17, 2022 at 04:40:39PM +0800, williamsukatube@163.com wrote:
> From: William Dean <williamsukatube@163.com>
> 
> It could directly return 'cgroup_update_dfl_csses' to simplify code.
> 
> Signed-off-by: William Dean <williamsukatube@163.com>

Applied to cgroup/for-6.1.

Thanks.

-- 
tejun

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH -next] cgroup: simplify code in cgroup_apply_control
@ 2022-09-24  2:52   ` Tejun Heo
  0 siblings, 0 replies; 6+ messages in thread
From: Tejun Heo @ 2022-09-24  2:52 UTC (permalink / raw)
  To: williamsukatube-9Onoh4P/yGk
  Cc: lizefan.x-EC8Uxl6Npydl57MIdRCFDg, hannes-druUgvl0LCNAfugRpC6u6w,
	cgroups-u79uwXL29TY76Z2rM5mHXA,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA

On Sat, Sep 17, 2022 at 04:40:39PM +0800, williamsukatube-9Onoh4P/yGk@public.gmane.org wrote:
> From: William Dean <williamsukatube-9Onoh4P/yGk@public.gmane.org>
> 
> It could directly return 'cgroup_update_dfl_csses' to simplify code.
> 
> Signed-off-by: William Dean <williamsukatube-9Onoh4P/yGk@public.gmane.org>

Applied to cgroup/for-6.1.

Thanks.

-- 
tejun

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2022-09-24  2:53 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-17  8:40 [PATCH -next] cgroup: simplify code in cgroup_apply_control williamsukatube
2022-09-17  8:40 ` williamsukatube-9Onoh4P/yGk
2022-09-19 10:49 ` Mukesh Ojha
2022-09-19 10:49   ` Mukesh Ojha
2022-09-24  2:52 ` Tejun Heo
2022-09-24  2:52   ` Tejun Heo

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.