[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <883d3ab7-b2df-9b9a-7681-1019ce3b9e18@redhat.com>
Date: Wed, 17 Oct 2018 11:45:50 +0200
From: David Hildenbrand <david@...hat.com>
To: Oscar Salvador <osalvador@...hadventures.net>
Cc: akpm@...ux-foundation.org, mhocko@...e.com,
dan.j.williams@...el.com, yasu.isimatu@...il.com,
rppt@...ux.vnet.ibm.com, malat@...ian.org,
linux-kernel@...r.kernel.org, pavel.tatashin@...rosoft.com,
jglisse@...hat.com, Jonathan.Cameron@...wei.com, rafael@...nel.org,
dave.jiang@...el.com, linux-mm@...ck.org,
alexander.h.duyck@...ux.intel.com,
Oscar Salvador <osalvador@...e.de>
Subject: Re: [PATCH 2/5] mm/memory_hotplug: Create add/del_device_memory
functions
On 17/10/2018 11:33, Oscar Salvador wrote:
>>> /*
>>> * For device private memory we call add_pages() as we only need to
>>> * allocate and initialize struct page for the device memory. More-
>>> @@ -1096,20 +1100,17 @@ static int hmm_devmem_pages_create(struct hmm_devmem *devmem)
>>> * want the linear mapping and thus use arch_add_memory().
>>> */
>>
>> Some parts of this comment should be moved into add_device_memory now.
>> (e.g. we call add_pages() ...)
>
> I agree.
>
>>> +#ifdef CONFIG_ZONE_DEVICE
>>> +int del_device_memory(int nid, unsigned long start, unsigned long size,
>>> + struct vmem_altmap *altmap, bool mapping)
>>> +{
>>> + int ret;
>>
>> nit: personally I prefer short parameters last in the list.
>
> I do not have a strong opinion here.
> If people think that long parameters should be placed at the end because
> it improves readability, I am ok with moving them there.
>
>> Can you document for both functions that they should be called with the
>> memory hotplug lock in write?
>
> Sure, I will do that in the next version, once I get some more feedback.
>
>> Apart from that looks good to me.
>
> Thanks for reviewing it David ;-)!
> May I assume your Reviewed-by here (if the above comments are addressed)?
Here you go ;)
Reviewed-by: David Hildenbrand <david@...hat.com>
I'm planning to look into the other patches as well, but I'll be busy
with traveling and KVM forum the next 1.5 weeks.
Cheers!
--
Thanks,
David / dhildenb
Powered by blists - more mailing lists