All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] cgroup: remove for_each_e_css
@ 2020-01-14 12:09 ` Alex Shi
  0 siblings, 0 replies; 4+ messages in thread
From: Alex Shi @ 2020-01-14 12:09 UTC (permalink / raw)
  Cc: Tejun Heo, Li Zefan, Johannes Weiner, cgroups, linux-kernel

After commit 37ff9f8f4742 ("cgroup: make cgroup[_taskset]_migrate()
take cgroup_r', No one use this macro.
So it'e better to remove.

Signed-off-by: Alex Shi <alex.shi@linux.alibaba.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Li Zefan <lizefan@huawei.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: cgroups@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
---
 kernel/cgroup/cgroup.c | 15 ---------------
 1 file changed, 15 deletions(-)

diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c
index 735af8f15f95..7d916ad33e59 100644
--- a/kernel/cgroup/cgroup.c
+++ b/kernel/cgroup/cgroup.c
@@ -663,21 +663,6 @@ struct cgroup_subsys_state *of_css(struct kernfs_open_file *of)
 		else
 
 /**
- * for_each_e_css - iterate all effective css's of a cgroup
- * @css: the iteration cursor
- * @ssid: the index of the subsystem, CGROUP_SUBSYS_COUNT after reaching the end
- * @cgrp: the target cgroup to iterate css's of
- *
- * Should be called under cgroup_[tree_]mutex.
- */
-#define for_each_e_css(css, ssid, cgrp)					    \
-	for ((ssid) = 0; (ssid) < CGROUP_SUBSYS_COUNT; (ssid)++)	    \
-		if (!((css) = cgroup_e_css_by_mask(cgrp,		    \
-						   cgroup_subsys[(ssid)]))) \
-			;						    \
-		else
-
-/**
  * do_each_subsys_mask - filter for_each_subsys with a bitmask
  * @ss: the iteration cursor
  * @ssid: the index of @ss, CGROUP_SUBSYS_COUNT after reaching the end
-- 
1.8.3.1


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

* [PATCH] cgroup: remove for_each_e_css
@ 2020-01-14 12:09 ` Alex Shi
  0 siblings, 0 replies; 4+ messages in thread
From: Alex Shi @ 2020-01-14 12:09 UTC (permalink / raw)
  Cc: Tejun Heo, Li Zefan, Johannes Weiner, cgroups, linux-kernel

After commit 37ff9f8f4742 ("cgroup: make cgroup[_taskset]_migrate()
take cgroup_r', No one use this macro.
So it'e better to remove.

Signed-off-by: Alex Shi <alex.shi@linux.alibaba.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Li Zefan <lizefan@huawei.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: cgroups@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
---
 kernel/cgroup/cgroup.c | 15 ---------------
 1 file changed, 15 deletions(-)

diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c
index 735af8f15f95..7d916ad33e59 100644
--- a/kernel/cgroup/cgroup.c
+++ b/kernel/cgroup/cgroup.c
@@ -663,21 +663,6 @@ struct cgroup_subsys_state *of_css(struct kernfs_open_file *of)
 		else
 
 /**
- * for_each_e_css - iterate all effective css's of a cgroup
- * @css: the iteration cursor
- * @ssid: the index of the subsystem, CGROUP_SUBSYS_COUNT after reaching the end
- * @cgrp: the target cgroup to iterate css's of
- *
- * Should be called under cgroup_[tree_]mutex.
- */
-#define for_each_e_css(css, ssid, cgrp)					    \
-	for ((ssid) = 0; (ssid) < CGROUP_SUBSYS_COUNT; (ssid)++)	    \
-		if (!((css) = cgroup_e_css_by_mask(cgrp,		    \
-						   cgroup_subsys[(ssid)]))) \
-			;						    \
-		else
-
-/**
  * do_each_subsys_mask - filter for_each_subsys with a bitmask
  * @ss: the iteration cursor
  * @ssid: the index of @ss, CGROUP_SUBSYS_COUNT after reaching the end
-- 
1.8.3.1


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

* Re: [PATCH] cgroup: remove for_each_e_css
  2020-01-14 12:09 ` Alex Shi
@ 2020-01-14 13:04   ` Shaokun Zhang
  -1 siblings, 0 replies; 4+ messages in thread
From: Shaokun Zhang @ 2020-01-14 13:04 UTC (permalink / raw)
  To: Alex Shi; +Cc: Tejun Heo, Li Zefan, Johannes Weiner, cgroups, linux-kernel

Hi,

https://spinics.net/lists/cgroups/msg23131.html

Thanks,

On 2020/1/14 20:09, Alex Shi wrote:
> After commit 37ff9f8f4742 ("cgroup: make cgroup[_taskset]_migrate()
> take cgroup_r', No one use this macro.
> So it'e better to remove.
> 
> Signed-off-by: Alex Shi <alex.shi@linux.alibaba.com>
> Cc: Tejun Heo <tj@kernel.org>
> Cc: Li Zefan <lizefan@huawei.com>
> Cc: Johannes Weiner <hannes@cmpxchg.org>
> Cc: cgroups@vger.kernel.org
> Cc: linux-kernel@vger.kernel.org
> ---
>  kernel/cgroup/cgroup.c | 15 ---------------
>  1 file changed, 15 deletions(-)
> 
> diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c
> index 735af8f15f95..7d916ad33e59 100644
> --- a/kernel/cgroup/cgroup.c
> +++ b/kernel/cgroup/cgroup.c
> @@ -663,21 +663,6 @@ struct cgroup_subsys_state *of_css(struct kernfs_open_file *of)
>  		else
>  
>  /**
> - * for_each_e_css - iterate all effective css's of a cgroup
> - * @css: the iteration cursor
> - * @ssid: the index of the subsystem, CGROUP_SUBSYS_COUNT after reaching the end
> - * @cgrp: the target cgroup to iterate css's of
> - *
> - * Should be called under cgroup_[tree_]mutex.
> - */
> -#define for_each_e_css(css, ssid, cgrp)					    \
> -	for ((ssid) = 0; (ssid) < CGROUP_SUBSYS_COUNT; (ssid)++)	    \
> -		if (!((css) = cgroup_e_css_by_mask(cgrp,		    \
> -						   cgroup_subsys[(ssid)]))) \
> -			;						    \
> -		else
> -
> -/**
>   * do_each_subsys_mask - filter for_each_subsys with a bitmask
>   * @ss: the iteration cursor
>   * @ssid: the index of @ss, CGROUP_SUBSYS_COUNT after reaching the end
> 


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

* Re: [PATCH] cgroup: remove for_each_e_css
@ 2020-01-14 13:04   ` Shaokun Zhang
  0 siblings, 0 replies; 4+ messages in thread
From: Shaokun Zhang @ 2020-01-14 13:04 UTC (permalink / raw)
  To: Alex Shi; +Cc: Tejun Heo, Li Zefan, Johannes Weiner, cgroups, linux-kernel

Hi,

https://spinics.net/lists/cgroups/msg23131.html

Thanks,

On 2020/1/14 20:09, Alex Shi wrote:
> After commit 37ff9f8f4742 ("cgroup: make cgroup[_taskset]_migrate()
> take cgroup_r', No one use this macro.
> So it'e better to remove.
> 
> Signed-off-by: Alex Shi <alex.shi@linux.alibaba.com>
> Cc: Tejun Heo <tj@kernel.org>
> Cc: Li Zefan <lizefan@huawei.com>
> Cc: Johannes Weiner <hannes@cmpxchg.org>
> Cc: cgroups@vger.kernel.org
> Cc: linux-kernel@vger.kernel.org
> ---
>  kernel/cgroup/cgroup.c | 15 ---------------
>  1 file changed, 15 deletions(-)
> 
> diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c
> index 735af8f15f95..7d916ad33e59 100644
> --- a/kernel/cgroup/cgroup.c
> +++ b/kernel/cgroup/cgroup.c
> @@ -663,21 +663,6 @@ struct cgroup_subsys_state *of_css(struct kernfs_open_file *of)
>  		else
>  
>  /**
> - * for_each_e_css - iterate all effective css's of a cgroup
> - * @css: the iteration cursor
> - * @ssid: the index of the subsystem, CGROUP_SUBSYS_COUNT after reaching the end
> - * @cgrp: the target cgroup to iterate css's of
> - *
> - * Should be called under cgroup_[tree_]mutex.
> - */
> -#define for_each_e_css(css, ssid, cgrp)					    \
> -	for ((ssid) = 0; (ssid) < CGROUP_SUBSYS_COUNT; (ssid)++)	    \
> -		if (!((css) = cgroup_e_css_by_mask(cgrp,		    \
> -						   cgroup_subsys[(ssid)]))) \
> -			;						    \
> -		else
> -
> -/**
>   * do_each_subsys_mask - filter for_each_subsys with a bitmask
>   * @ss: the iteration cursor
>   * @ssid: the index of @ss, CGROUP_SUBSYS_COUNT after reaching the end
> 


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

end of thread, other threads:[~2020-01-14 13:05 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-14 12:09 [PATCH] cgroup: remove for_each_e_css Alex Shi
2020-01-14 12:09 ` Alex Shi
2020-01-14 13:04 ` Shaokun Zhang
2020-01-14 13:04   ` Shaokun Zhang

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.