Re: [PATCH v2] mm/mm_init: handle alloc_percpu failure in free_area_init_core_hotplug
From: Mike Rapoport
Date: Thu Jul 02 2026 - 05:25:13 EST
On Wed, 01 Jul 2026 18:16:13 -0400, Gregory Price wrote:
> We miss a failed allocation check for pgdat->per_cpu_nodestats, which
> results in a NULL deref when we offset into the per-cpu area.
>
> Propagate -ENOMEM up the stack and leave per_cpu_nodestats pointing
> at boot_nodestats so a later online can retry the allocation.
>
> hotadd_init_pgdat() returns NULL on failure, which __try_online_node()
> already maps to -ENOMEM.
>
> [...]
Applied to fixes branch of memblock.git tree, thanks!
[1/1] mm/mm_init: handle alloc_percpu failure in free_area_init_core_hotplug
commit: 2ebce860bdd7ae5e13002811bc9bbbf33fcfc221
tree: https://git.kernel.org/pub/scm/linux/kernel/git/rppt/memblock
branch: fixes
--
Sincerely yours,
Mike.