[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <57334d15.524a370a.4b1f7.fffff006@mx.google.com>
Date: Wed, 11 May 2016 08:17:41 -0700 (PDT)
From: Yasuaki Ishimatsu <yasu.isimatu@...il.com>
To: Reza Arbab <arbab@...ux.vnet.ibm.com>
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Andrew Morton <akpm@...ux-foundation.org>,
Daniel Kiper <daniel.kiper@...cle.com>,
Dan Williams <dan.j.williams@...el.com>,
Vlastimil Babka <vbabka@...e.cz>,
Tang Chen <tangchen@...fujitsu.com>,
Joonsoo Kim <iamjoonsoo.kim@....com>,
David Vrabel <david.vrabel@...rix.com>,
Vitaly Kuznetsov <vkuznets@...hat.com>,
David Rientjes <rientjes@...gle.com>,
Andrew Banman <abanman@....com>,
Chen Yucong <slaoub@...il.com>, linux-mm@...ck.org,
linux-kernel@...r.kernel.org,
Yasuaki Ishimatsu <isimatu.yasuaki@...fujitsu.com>
Subject: Re: [PATCH 2/3] memory-hotplug: more general validation of zone
during online
On Tue, 10 May 2016 15:39:43 -0500
Reza Arbab <arbab@...ux.vnet.ibm.com> wrote:
> On Tue, May 10, 2016 at 11:08:56AM -0700, Yasuaki Ishimatsu wrote:
> >On Mon, 9 May 2016 12:53:38 -0500
> >Reza Arbab <arbab@...ux.vnet.ibm.com> wrote:
> >> * If X is lower than Y, the onlined memory must lie at the end of X.
> >> * If X is higher than Y, the onlined memory must lie at the start of X.
> >
> >If memory address has hole, memory address gets uncotinuous. Then memory
> >cannot be changed the zone by above the two conditions. So the conditions
> >shouold be removed.
>
> I don't understand what you mean by this. Could you give an example?
> +int zone_can_shift(unsigned long pfn, unsigned long nr_pages,
> + enum zone_type target)
> +{
<snip>
> + if (idx < target) {
> + /* pages must be at end of current zone */
> + if (pfn + nr_pages != zone_end_pfn(zone))
> + return 0;
<snip>
> + if (target < idx) {
> + /* pages must be at beginning of current zone */
> + if (pfn != zone->zone_start_pfn)
> + return 0;
According your patch, memory address must be continuous for changing zone.
So if memory address is uncontinuous as follows, memory address 0x180000000-0x1FFFFFFFF
can be changed from ZONE_NORMAL to ZONE_MOVABLE. But memory address 0x80000000-0xFFFFFFFF
can not be changed from ZONE_NORMAL to ZONE_MOVABLE since it does not meet
above condition.
Memory address
0x80000000 - 0xFFFFFFFF
0x180000000 - 0x1FFFFFFFF
Thanks,
Yasuaki Ishimatsu
Powered by blists - more mailing lists