Thread (15 messages) 15 messages, 4 authors, 2021-10-01

Re: [PATCH v1 2/4] memblock: allow to specify flags with memblock_add_node()

From: David Hildenbrand <hidden>
Date: 2021-09-29 16:30:19
Also in: kexec, linux-m68k, linux-mips, linux-s390, lkml

On 29.09.21 18:25, Mike Rapoport wrote:
On Mon, Sep 27, 2021 at 05:05:16PM +0200, David Hildenbrand wrote:
quoted
We want to specify flags when hotplugging memory. Let's prepare to pass
flags to memblock_add_node() by adjusting all existing users.

Note that when hotplugging memory the system is already up and running
and we don't want to add the memory first and apply flags later: it
should happen within one memblock call.
Why is it important that the system is up and why it should happen in a
single call?
I don't mind adding flags parameter to memblock_add_node() but this
changelog does not really explain the reasons to do it.
"After memblock_add_node(), we could race with anybody performing a 
search for MEMBLOCK_NONE, like kexec_file -- and that only happens once 
the system is already up and running. So we want both steps to happen 
atomically."

I can add that to the patch description.

(I think it still won't be completely atomic because memblock isn't 
properly implementing locking yet, but that's a different story)

-- 
Thanks,

David / dhildenb

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help