Re: [PATCH v8 04/14] drivers: dax: use pgtable_has_pmd_leaves()
From: David Hildenbrand (Arm)
Date: Fri Oct 02 2026 - 15:18:50 EST
On 9/18/26 03:45, Luiz Capitulino wrote:
> dax_align_valid() uses has_transparent_hugepage() to check if PMD-sized
> pages are supported, use pgtable_has_pmd_leaves() instead.
>
> Acked-by: David Hildenbrand (Red Hat) <david@xxxxxxxxxx>
> Signed-off-by: Luiz Capitulino <luizcap@xxxxxxxxxx>
> ---
> drivers/dax/dax-private.h | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/dax/dax-private.h b/drivers/dax/dax-private.h
> index 607a53a91f58..18a6295aa766 100644
> --- a/drivers/dax/dax-private.h
> +++ b/drivers/dax/dax-private.h
> @@ -121,7 +121,7 @@ static inline bool dax_align_valid(unsigned long align)
> {
> if (align == PUD_SIZE && IS_ENABLED(CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE_PUD))
> return true;
> - if (align == PMD_SIZE && has_transparent_hugepage())
> + if (align == PMD_SIZE && pgtable_has_pmd_leaves())
> return true;
> if (align == PAGE_SIZE)
> return true;
The main part why we don't see any change is that dax_align_valid() is wrapped
in the #ifdef CONFIG_TRANSPARENT_HUGEPAGE today.
Might we worth spelling that out in the patch description.
--
Cheers,
David