[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <abfb5b1c-45cf-4b37-bca3-75c6028cf3b0@infradead.org>
Date: Fri, 10 Nov 2023 13:02:15 -0800
From: Randy Dunlap <rdunlap@...radead.org>
To: zhaimingbing <zhaimingbing@...s.chinamobile.com>
Cc: James.Bottomley@...senpartnership.com,
linux-kernel@...r.kernel.org, linux-mm@...ck.org
Subject: Re: [PATCH V2] mm:hugetlb_cgroup: Optimize variable initialization
On 11/7/23 13:13, zhaimingbing wrote:
> Initialize 'max' with 'unsigned long' instead of 'long'.
>
There is no variable initialization here, so the $Subject
does not match what is being changed.
Also there is no description of Why this change is needed.
> Signed-off-by: zhaimingbing <zhaimingbing@...s.chinamobile.com>
> ---
> mm/hugetlb_cgroup.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/mm/hugetlb_cgroup.c b/mm/hugetlb_cgroup.c
> index dedd2edb0..d4ca2ac55 100644
> --- a/mm/hugetlb_cgroup.c
> +++ b/mm/hugetlb_cgroup.c
> @@ -685,7 +685,7 @@ static char *mem_fmt(char *buf, int size, unsigned long hsize)
> static int __hugetlb_events_show(struct seq_file *seq, bool local)
> {
> int idx;
> - long max;
> + unsigned long max;
> struct cftype *cft = seq_cft(seq);
> struct hugetlb_cgroup *h_cg = hugetlb_cgroup_from_css(seq_css(seq));
>
--
~Randy
Powered by blists - more mailing lists