Re: [PATCH mm-unstable v1 2/5] mm: introduce is_pmd_order helper

Zi Yan
2026-02-12T16:11:19Z

On 11 Feb 2026, at 21:18, Nico Pache wrote:

> In order to add mTHP support to khugepaged, we will often be checking if a
> given order is (or is not) a PMD order. Some places in the kernel already
> use this check, so lets create a simple helper function to keep the code
> clean and readable.
>
> Reviewed-by: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
> Suggested-by: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
> Signed-off-by: Nico Pache <npache@redhat.com>
>
> arches# pick b3ace8be204f # mm/khugepaged: rename hpage_collapse_* to collapse_*
> ---
> include/linux/huge_mm.h | 5 +++++
> mm/huge_memory.c | 2 +-
> mm/khugepaged.c | 4 ++--
> mm/mempolicy.c | 2 +-
> mm/page_alloc.c | 2 +-
> 5 files changed, 10 insertions(+), 5 deletions(-)
>
LGTM.

Reviewed-by: Zi Yan <ziy@nvidia.com>

Best Regards,
Yan, Zi