Subject: Re: [PATCH V4 2/3] mm/sparsemem: Enable vmem_altmap support in vmemmap_alloc_block_buf()

From: Catalin Marinas <[email-masked]>
Date: Wed, 8 Jul 2020 14:25:20 +0100

On Mon, Jul 06, 2020 at 08:26:17AM +0530, Anshuman Khandual wrote:
> There are many instances where vmemap allocation is often switched between
> regular memory and device memory just based on whether altmap is available
> or not. vmemmap_alloc_block_buf() is used in various platforms to allocate
> vmemmap mappings. Lets also enable it to handle altmap based device memory
> allocation along with existing regular memory allocations. This will help
> in avoiding the altmap based allocation switch in many places. To summarize
> there are two different methods to call vmemmap_alloc_block_buf().
> 
> vmemmap_alloc_block_buf(size, node, NULL)   /* Allocate from system RAM */
> vmemmap_alloc_block_buf(size, node, altmap) /* Allocate from altmap */
> 
> This converts altmap_alloc_block_buf() into a static function, drops it's

s/it's/its/

> entry from the header and updates Documentation/vm/memory-model.rst.
> 
> Cc: Jonathan Corbet <[email-masked]>
> Cc: Catalin Marinas <[email-masked]>
> Cc: Will Deacon <[email-masked]>
> Cc: Benjamin Herrenschmidt <[email-masked]>
> Cc: Paul Mackerras <[email-masked]>
> Cc: Michael Ellerman <[email-masked]>
> Cc: Dave Hansen <[email-masked]>
> Cc: Andy Lutomirski <[email-masked]>
> Cc: Peter Zijlstra <[email-masked]>
> Cc: Thomas Gleixner <[email-masked]>
> Cc: Ingo Molnar <[email-masked]>
> Cc: Borislav Petkov <[email-masked]>
> Cc: "H. Peter Anvin" <[email-masked]>
> Cc: Andrew Morton <[email-masked]>
> Cc: [email-masked]
> Cc: [email-masked]
> Cc: [email-masked]
> Cc: [email-masked]
> Cc: [email-masked]
> Cc: [email-masked]
> Tested-by: Jia He <[email-masked]>
> Suggested-by: Robin Murphy <[email-masked]>
> Signed-off-by: Anshuman Khandual <[email-masked]>

With the fallback argument dropped, the patch looks fine to me.

Reviewed-by: Catalin Marinas <[email-masked]>