Re: [PATCH] memory_hotplug: fix the panic when memory end is not on the section boundary

From: Michal Hocko
Date: Mon Sep 10 2018 - 10:19:51 EST


On Mon 10-09-18 14:11:45, Pavel Tatashin wrote:
> Hi Michal,
>
> It is tricky, but probably can be done. Either change
> memmap_init_zone() or its caller to also cover the ends and starts of
> unaligned sections to initialize and reserve pages.
>
> The same thing would also need to be done in deferred_init_memmap() to
> cover the deferred init case.

Well, I am not sure TBH. I have to think about that much more. Maybe it
would be much more simple to make sure that we will never add incomplete
memblocks and simply refuse them during the discovery. At least for now.
--
Michal Hocko
SUSE Labs