Re: [PATCH RFC] mm/memblock: Fix reserve_mem allocation overlapping KHO scratch regions
From: Mike Rapoport
Date: Mon Dec 01 2025 - 01:50:59 EST
Hi Swaraj,
On Sun, Nov 30, 2025 at 09:15:39PM +0000, Swaraj Gaikwad wrote:
> Hi Mike,
>
> Thanks for the feedback.
>
> This patch was sent as an RFC because I wanted to confirm whether the
> overall approach is acceptable before preparing a fully tested version.
> I will send a properly tested patch once I get confirmation that this
> direction makes sense.
I didn't look into the details, but I think what you propose won't work.
The first kernel allocates KHO scratch after parsing reserve_mem and the
second kernel allocates everything from KHO scratch at the time
early_params are parsed.
> I’m reviewing how reserve_mem= paths are exercised so I can build an
> appropriate test setup. Any guidance on recommended testing for this
> area is appreciated.
In general to test changes to memblock and other early code I use qemu and
some scripts around it.
> Thanks,
> Swaraj
--
Sincerely yours,
Mike.