Re: [PATCH v5 04/17] mm/sparse-vmemmap: initialize shared tail vmemmap pages on allocation

From: David Hildenbrand (Arm)

Date: Wed Sep 09 2026 - 06:02:47 EST


On 8/25/26 10:45, Muchun Song wrote:
> The shared tail vmemmap page allocated in vmemmap_get_tail() used to be
> left uninitialized, because memmap_init_range() would later overwrite
> it. That forced users such as HugeTLB to defer the initialization to
> their own setup paths.
>
> Now that memmap_init_range() skips shared tail vmemmap pages, initialize
> them immediately in vmemmap_get_tail() with init_compound_tail()
> instead.
>
> This moves the initialization to the point where the shared tail page is

You are not really moving the initialization? I see a new initialization being
added but none getting removed.

Wouldn't hugetlb_bootmem_struct_page_init() have to be updated as well (as the
comment you are changing indicates) or what am I missing?

--
Cheers,

David