[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <a2ebe8c0-916e-1117-acfd-0ac2300a7dfd@redhat.com>
Date: Wed, 3 Apr 2019 10:36:04 +0200
From: David Hildenbrand <david@...hat.com>
To: Oscar Salvador <osalvador@...e.de>,
Michal Hocko <mhocko@...nel.org>
Cc: akpm@...ux-foundation.org, dan.j.williams@...el.com,
Jonathan.Cameron@...wei.com, anshuman.khandual@....com,
linux-kernel@...r.kernel.org, linux-mm@...ck.org
Subject: Re: [PATCH 0/4] mm,memory_hotplug: allocate memmap from hotadded
memory
On 03.04.19 10:34, Oscar Salvador wrote:
> On Wed, Apr 03, 2019 at 10:12:32AM +0200, Michal Hocko wrote:
>> What does prevent calling somebody arch_add_memory for a range spanning
>> multiple memblocks from a driver directly. In other words aren't you
>> making assumptions about a future usage based on the qemu usecase?
>
> Well, right now they cannot as it is not exported.
> But if we want to do it in the future, then yes, I would have to
> be more careful because I made the assumption that hot-add/hot-remove
> are working with the same granularity, which is the case right now.
>
> Given said this, I think that something like you said before, giving
> the option to the caller to specify whether it wants vmemmaps per the
> whole hot-added range or per memblock is a reasonable thing to do.
> That way, there will not be a problem working with different granularities
> in hot-add/hot-remove operations and we would be on safe side.
There might still be an issue if the person adding memory might be
somebody else removing memory. I am not yet sure if we should even allow
add_memory/remove_memory with different granularity. But as I noted,
ACPI and powernv.
--
Thanks,
David / dhildenb
Powered by blists - more mailing lists