Re: [PATCH] cgroup: provide a macro helper to iterate a cgroup's ancestors

2019-06-27 Thread Zefan Li
On 2019/6/27 18:19, Peng Wang wrot: Use for_each_ancestor macro to iterate a cgroup's ancestors for clarity.> This patch doesn't make much sense to me. Because it does not reduce lines of code, and I don't think it will reduce the size of the kernel, and the original code is not bad in readab

[PATCH] cgroup: provide a macro helper to iterate a cgroup's ancestors

2019-06-27 Thread Peng Wang
Use for_each_ancestor macro to iterate a cgroup's ancestors for clarity. Signed-off-by: Peng Wang --- include/linux/cgroup.h | 11 +++ kernel/cgroup/cgroup.c | 7 +++ kernel/cgroup/freezer.c | 2 +- kernel/cgroup/rstat.c | 4 ++-- 4 files changed, 17 insertions(+), 7 deletions