[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <fab2431f-a715-4ccf-88cf-9432212d804a@kernel.org>
Date: Thu, 27 Nov 2025 09:07:21 +0100
From: "David Hildenbrand (Red Hat)" <david@...nel.org>
To: Sahil Chandna <chandna.sahil@...il.com>, akpm@...ux-foundation.org,
lorenzo.stoakes@...cle.com, mhocko@...e.com, vbabka@...e.cz,
rppt@...nel.org, surenb@...gle.com, hannes@...xchg.org,
shakeel.butt@...ux.dev, zhengqi.arch@...edance.com, Liam.Howlett@...cle.com,
weixugc@...gle.com, axelrasmussen@...gle.com, yuanchu@...gle.com,
yosry.ahmed@...ux.dev, nphamcs@...il.com, chengming.zhou@...ux.dev,
linux-mm@...ck.org, linux-kernel@...r.kernel.org
Cc: Matthew Wilcox <willy@...radead.org>,
David Laight <david.laight.linux@...il.com>
Subject: Re: [PATCH v3 1/3] mm: pagewalk: simplify hugepage boundary
calculation using min()
On 11/27/25 06:11, Sahil Chandna wrote:
> Use the min() macro to compute the minimum value instead of an explicit
> ternary expression. This improves readability and matches common kernel
> style. Also change the return hugepage boundary expression for better
> clarity.
>
> This was flagged by Coccinelle
> (misc/minmax.cocci) as an opportunity to use min().
>
> Found by: make coccicheck MODE=report M=mm/
> No functional change intended.
>
> Suggested-by: David Hildenbrand (Red Hat) <david@...nel.org>
> Suggested-by: Matthew Wilcox <willy@...radead.org>
> Suggested-by: David Laight <david.laight.linux@...il.com>
> Signed-off-by: Sahil Chandna <chandna.sahil@...il.com>
> ---
Acked-by: David Hildenbrand (Red Hat) <david@...nel.org>
--
Cheers
David
Powered by blists - more mailing lists