On Tue, Jan 26, 2021 at 10:36:21AM +0100, David Hildenbrand wrote:
I think either keep it completely simple (only free vmemmap of hugetlb
pages allocated early during boot - which is what's not sufficient for
some use cases) or implement the full thing properly (meaning, solve
most challenging issues to get the basics running).
I don't want to have some easy parts of complex features merged (e.g.,
breaking other stuff as you indicate below), and later finding out "it's
not that easy" again and being stuck with it forever.
Well, we could try to do an optimistic allocation, without tricky loopings.
If that fails, refuse to shrink the pool at that moment.
The user could always try to shrink it later via /proc/sys/vm/nr_hugepages
interface.
But I am just thinking out loud..
Of course, this means that e.g: memory-hotplug (hot-remove) will not fully work
when this in place, but well.
Can you elaborate? Are we're talking about having hugepages in
ZONE_MOVABLE that are not migratable (and/or dissolvable) anymore? Than
a clear NACK from my side.
Pretty much, yeah.