Re: [PATCH] cgroup: Refactor two assignments in css_task_iter_next_css_set()

2020-06-14 Thread Zefan Li
On 2020/6/15 7:22, zzuedu2...@163.com wrote: > On Sun, 2020-06-14 at 18:10 +0800, James.Bottomley@xxx wrote: > >> it's arguable that having two statements instead of one makes the code >> marginally more readable. > > Above the function there is a similar line of code: > l = it->tcset_pos->ne

Re: [PATCH] cgroup: Refactor two assignments in css_task_iter_next_css_set()

2020-06-14 Thread zzuedu2000
On Sun, 2020-06-14 at 18:10 +0800, James.Bottomley@xxx wrote: > it's arguable that having two statements instead of one makes the code > marginally more readable. Above the function there is a similar line of code: l = it->tcset_pos->next; One line of code makes the code style consistent and

Re: [PATCH] cgroup: Refactor two assignments in css_task_iter_next_css_set()

2020-06-14 Thread James Bottomley
On Sun, 2020-06-14 at 10:28 +0800, zzuedu2...@163.com wrote: > From: Wei Fenghai > > Combine two assignments for the variable ā€˜l’ into one statement. The problem with this commit message isn't the description, we can all see what the change does, it's the justification. Why is there any reason

[PATCH] cgroup: Refactor two assignments in css_task_iter_next_css_set()

2020-06-13 Thread zzuedu2000
From: Wei Fenghai Combine two assignments for the variable ā€˜l’ into one statement. Signed-off-by: Wei Fenghai --- kernel/cgroup/cgroup.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c index 1ea181a58465..c3e6db6e44d8 100644