[PATCH v6 5/8] LoongArch: Allow memblock arrays to resize

sashiko-bot at kernel.org sashiko-bot at kernel.org
Thu Oct 29 10:47:16 PDT 2026


> From: George Guo <guodongtai at kylinos.cn>
> 
> LoongArch never calls memblock_allow_resize(), so the reserved region
> array cannot grow beyond INIT_MEMBLOCK_RESERVED_REGIONS entries
> (INIT_MEMBLOCK_REGIONS + NR_CPUS).
> 
> After kexec, kho_memory_init() reserves every range preserved by KHO.
> Each range that is not adjacent to another one needs its own entry, so
> with enough scattered preserved pages the array overflows and the
> incoming kernel panics:
> 
>   Kernel panic - not syncing: memblock: cannot resize reserved array
>   Call Trace:
>    memblock_double_array+0x2d4/0x2f8
>    memblock_isolate_range+0x54/0x1a8
> [ ... ]
> preserved data.
> 
> Co-developed-by: Kexin Liu <liukexin at kylinos.cn>
> Signed-off-by: Kexin Liu <liukexin at kylinos.cn>
> Signed-off-by: George Guo <guodongtai at kylinos.cn>

Sashiko has reviewed this patch and found no issues.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261029172956.20791-1-dongtai.guo@linux.dev?part=5




More information about the kexec mailing list