Subject: Re: [PATCH v4 03/13] mm/vmemmap: Improve vmemmap_can_optimize and allow architectures to override

From: "Aneesh Kumar K.V" <[email-masked]>
Date: Tue, 11 Jul 2023 09:55:34 +0530

Christophe Leroy <[email-masked]> writes:

> Le 10/07/2023 à 18:08, Aneesh Kumar K.V a écrit :
>> dax vmemmap optimization requires a minimum of 2 PAGE_SIZE area within
>> vmemmap such that tail page mapping can point to the second PAGE_SIZE area.
>> Enforce that in vmemmap_can_optimize() function.
>> 
>> Architectures like powerpc also want to enable vmemmap optimization
>> conditionally (only with radix MMU translation). Hence allow architecture
>> override.
>> 
>> Signed-off-by: Aneesh Kumar K.V <[email-masked]>
>
> Reviewed-by: Christophe Leroy <[email-masked]>
>
> Why renaming vmemmap_can_optimize() to __vmemmap_can_optimize() and keep 
> it when vmemmap_can_optimize() has been override ? Is that because you 
> expect overriding version of vmemmap_can_optimize() to call 
> __vmemmap_can_optimize() ?
>

Yes, __vmemap_can_optimize will be used in patch 11
https://lore.kernel.org/linuxppc-dev/[email-masked]

-aneesh