Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-16 Thread Tang Chen
On 07/16/2015 05:20 AM, Tejun Heo wrote: On Wed, Jul 01, 2015 at 11:16:54AM +0800, Tang Chen wrote: ... - /* and there's no empty block */ - if (bi->start >= bi->end) + /* and there's no empty or non-exist block */ + if (bi->start >=

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-16 Thread Tang Chen
On 07/16/2015 05:20 AM, Tejun Heo wrote: On Wed, Jul 01, 2015 at 11:16:54AM +0800, Tang Chen wrote: ... - /* and there's no empty block */ - if (bi-start = bi-end) + /* and there's no empty or non-exist block */ + if (bi-start = bi-end ||

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-15 Thread Tang Chen
On 07/16/2015 05:20 AM, Tejun Heo wrote: On Wed, Jul 01, 2015 at 11:16:54AM +0800, Tang Chen wrote: ... - /* and there's no empty block */ - if (bi->start >= bi->end) + /* and there's no empty or non-exist block */ + if (bi->start >=

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-15 Thread Tejun Heo
On Wed, Jul 01, 2015 at 11:16:54AM +0800, Tang Chen wrote: ... > - /* and there's no empty block */ > - if (bi->start >= bi->end) > + /* and there's no empty or non-exist block */ > + if (bi->start >= bi->end || > +

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-15 Thread Tang Chen
On 07/16/2015 05:20 AM, Tejun Heo wrote: On Wed, Jul 01, 2015 at 11:16:54AM +0800, Tang Chen wrote: ... - /* and there's no empty block */ - if (bi-start = bi-end) + /* and there's no empty or non-exist block */ + if (bi-start = bi-end ||

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-15 Thread Tejun Heo
On Wed, Jul 01, 2015 at 11:16:54AM +0800, Tang Chen wrote: ... - /* and there's no empty block */ - if (bi-start = bi-end) + /* and there's no empty or non-exist block */ + if (bi-start = bi-end || +

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-07 Thread Tang Chen
On 07/07/2015 12:42 AM, Yasuaki Ishimatsu wrote: On Fri, 3 Jul 2015 09:26:05 +0800 Tang Chen wrote: On 07/02/2015 11:02 PM, Yasuaki Ishimatsu wrote: Hi Tang, On my box, if I run lscpu, the output looks like this: NUMA node0 CPU(s): 0-14,128-142 NUMA node1 CPU(s): 15-29,143-157

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-07 Thread Tang Chen
On 07/07/2015 12:42 AM, Yasuaki Ishimatsu wrote: On Fri, 3 Jul 2015 09:26:05 +0800 Tang Chen tangc...@cn.fujitsu.com wrote: On 07/02/2015 11:02 PM, Yasuaki Ishimatsu wrote: Hi Tang, On my box, if I run lscpu, the output looks like this: NUMA node0 CPU(s): 0-14,128-142 NUMA node1

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-06 Thread Yasuaki Ishimatsu
On Fri, 3 Jul 2015 09:26:05 +0800 Tang Chen wrote: > > On 07/02/2015 11:02 PM, Yasuaki Ishimatsu wrote: > > Hi Tang, > > > >> On my box, if I run lscpu, the output looks like this: > >> > >> NUMA node0 CPU(s): 0-14,128-142 > >> NUMA node1 CPU(s): 15-29,143-157 > >> NUMA node2 CPU(s): >

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-06 Thread Yasuaki Ishimatsu
On Fri, 3 Jul 2015 09:26:05 +0800 Tang Chen tangc...@cn.fujitsu.com wrote: On 07/02/2015 11:02 PM, Yasuaki Ishimatsu wrote: Hi Tang, On my box, if I run lscpu, the output looks like this: NUMA node0 CPU(s): 0-14,128-142 NUMA node1 CPU(s): 15-29,143-157 NUMA node2 CPU(s):

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-02 Thread Tang Chen
On 07/02/2015 11:02 PM, Yasuaki Ishimatsu wrote: Hi Tang, On my box, if I run lscpu, the output looks like this: NUMA node0 CPU(s): 0-14,128-142 NUMA node1 CPU(s): 15-29,143-157 NUMA node2 CPU(s): NUMA node3 CPU(s): NUMA node4 CPU(s): 62-76,190-204 NUMA node5 CPU(s):

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-02 Thread Yasuaki Ishimatsu
Hi Tang, > On my box, if I run lscpu, the output looks like this: > > NUMA node0 CPU(s): 0-14,128-142 > NUMA node1 CPU(s): 15-29,143-157 > NUMA node2 CPU(s): > NUMA node3 CPU(s): > NUMA node4 CPU(s): 62-76,190-204 > NUMA node5 CPU(s): 78-92,206-220 > > Node 2 and 3 are not

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-02 Thread Yasuaki Ishimatsu
Hi Tang, On my box, if I run lscpu, the output looks like this: NUMA node0 CPU(s): 0-14,128-142 NUMA node1 CPU(s): 15-29,143-157 NUMA node2 CPU(s): NUMA node3 CPU(s): NUMA node4 CPU(s): 62-76,190-204 NUMA node5 CPU(s): 78-92,206-220 Node 2 and 3 are not exist, but they

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-02 Thread Tang Chen
On 07/02/2015 11:02 PM, Yasuaki Ishimatsu wrote: Hi Tang, On my box, if I run lscpu, the output looks like this: NUMA node0 CPU(s): 0-14,128-142 NUMA node1 CPU(s): 15-29,143-157 NUMA node2 CPU(s): NUMA node3 CPU(s): NUMA node4 CPU(s): 62-76,190-204 NUMA node5 CPU(s):

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-01 Thread Xishi Qiu
On 2015/7/1 15:55, Tang Chen wrote: > > On 07/01/2015 02:25 PM, Xishi Qiu wrote: >> On 2015/7/1 11:16, Tang Chen wrote: >> >>> When parsing SRAT, all memory ranges are added into numa_meminfo. >>> In numa_init(), before entering numa_cleanup_meminfo(), all possible >>> memory ranges are in

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-01 Thread Tang Chen
On 07/01/2015 02:25 PM, Xishi Qiu wrote: On 2015/7/1 11:16, Tang Chen wrote: When parsing SRAT, all memory ranges are added into numa_meminfo. In numa_init(), before entering numa_cleanup_meminfo(), all possible memory ranges are in numa_meminfo. And numa_cleanup_meminfo() removes all ranges

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-01 Thread Xishi Qiu
On 2015/7/1 11:16, Tang Chen wrote: > When parsing SRAT, all memory ranges are added into numa_meminfo. > In numa_init(), before entering numa_cleanup_meminfo(), all possible > memory ranges are in numa_meminfo. And numa_cleanup_meminfo() removes > all ranges over max_pfn or empty. > > But, this

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-01 Thread Xishi Qiu
On 2015/7/1 15:55, Tang Chen wrote: On 07/01/2015 02:25 PM, Xishi Qiu wrote: On 2015/7/1 11:16, Tang Chen wrote: When parsing SRAT, all memory ranges are added into numa_meminfo. In numa_init(), before entering numa_cleanup_meminfo(), all possible memory ranges are in numa_meminfo. And

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-01 Thread Tang Chen
On 07/01/2015 02:25 PM, Xishi Qiu wrote: On 2015/7/1 11:16, Tang Chen wrote: When parsing SRAT, all memory ranges are added into numa_meminfo. In numa_init(), before entering numa_cleanup_meminfo(), all possible memory ranges are in numa_meminfo. And numa_cleanup_meminfo() removes all ranges

Re: [PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-07-01 Thread Xishi Qiu
On 2015/7/1 11:16, Tang Chen wrote: When parsing SRAT, all memory ranges are added into numa_meminfo. In numa_init(), before entering numa_cleanup_meminfo(), all possible memory ranges are in numa_meminfo. And numa_cleanup_meminfo() removes all ranges over max_pfn or empty. But, this only

[PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-06-30 Thread Tang Chen
When parsing SRAT, all memory ranges are added into numa_meminfo. In numa_init(), before entering numa_cleanup_meminfo(), all possible memory ranges are in numa_meminfo. And numa_cleanup_meminfo() removes all ranges over max_pfn or empty. But, this only works if the nodes are continuous. Let's

[PATCH 1/1] mem-hotplug: Handle node hole when initializing numa_meminfo.

2015-06-30 Thread Tang Chen
When parsing SRAT, all memory ranges are added into numa_meminfo. In numa_init(), before entering numa_cleanup_meminfo(), all possible memory ranges are in numa_meminfo. And numa_cleanup_meminfo() removes all ranges over max_pfn or empty. But, this only works if the nodes are continuous. Let's