Re: [PATCH 1/2] cgroup: rstat: use same convention to assign cgroup_base_stat

From: Tejun Heo
Date: Wed Jan 12 2022 - 14:57:53 EST


On Sat, Jan 08, 2022 at 12:38:16AM +0000, Wei Yang wrote:
> In function cgroup_base_stat_flush(), we update cgroup_base_stat by
> getting rstatc->bstat and adjust delta to related fields.
>
> There are two convention to assign cgroup_base_stat in this function:
>
> * rstat2 = rstat1
> * rstat2.cputime = rstat1.cputime
>
> The second convention may make audience think just field "cputime" is
> updated, while cputime is the only field in cgroup_base_stat.
>
> Let's use the same convention to eliminate this confusion.
>
> Signed-off-by: Wei Yang <richard.weiyang@xxxxxxxxx>

Applied 1-2 to cgroup/for-5.18.

Thanks.

--
tejun