Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v4)

2014-05-30 Thread Marcelo Tosatti
On Fri, May 30, 2014 at 08:48:41AM -0500, Christoph Lameter wrote: > On Thu, 29 May 2014, Andrew Morton wrote: > > > > > > > if (!nodemask && gfp_zone(gfp_mask) < policy_zone) > > > nodemask = _states[N_ONLINE]; > > > > OK, thanks, I made the patch go away for now. > > > > And

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v5)

2014-05-30 Thread Andi Kleen
On Fri, May 30, 2014 at 08:50:56AM -0500, Christoph Lameter wrote: > On Thu, 29 May 2014, David Rientjes wrote: > > > When I said that my point about mempolicies needs more thought, I wasn't > > expecting that there would be no discussion -- at least _something_ that > > would say why we don't

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v5)

2014-05-30 Thread Christoph Lameter
On Thu, 29 May 2014, David Rientjes wrote: > When I said that my point about mempolicies needs more thought, I wasn't > expecting that there would be no discussion -- at least _something_ that > would say why we don't care about the mempolicy case. Lets get Andi involved here too. > The

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v4)

2014-05-30 Thread Christoph Lameter
On Thu, 29 May 2014, Andrew Morton wrote: > > > > if (!nodemask && gfp_zone(gfp_mask) < policy_zone) > > nodemask = _states[N_ONLINE]; > > OK, thanks, I made the patch go away for now. > And another issue is that the policy_zone may be highmem on 32 bit platforms which will

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v5)

2014-05-30 Thread Marcelo Tosatti
On Thu, May 29, 2014 at 04:54:00PM -0700, David Rientjes wrote: > On Thu, 29 May 2014, Marcelo Tosatti wrote: > > > diff --git a/kernel/cpuset.c b/kernel/cpuset.c > > index 3d54c41..3bbc23f 100644 > > --- a/kernel/cpuset.c > > +++ b/kernel/cpuset.c > > @@ -2374,6 +2374,7 @@ static struct cpuset

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v5)

2014-05-30 Thread Marcelo Tosatti
On Thu, May 29, 2014 at 04:54:00PM -0700, David Rientjes wrote: On Thu, 29 May 2014, Marcelo Tosatti wrote: diff --git a/kernel/cpuset.c b/kernel/cpuset.c index 3d54c41..3bbc23f 100644 --- a/kernel/cpuset.c +++ b/kernel/cpuset.c @@ -2374,6 +2374,7 @@ static struct cpuset

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v4)

2014-05-30 Thread Christoph Lameter
On Thu, 29 May 2014, Andrew Morton wrote: if (!nodemask gfp_zone(gfp_mask) policy_zone) nodemask = node_states[N_ONLINE]; OK, thanks, I made the patch go away for now. And another issue is that the policy_zone may be highmem on 32 bit platforms which will result in

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v5)

2014-05-30 Thread Christoph Lameter
On Thu, 29 May 2014, David Rientjes wrote: When I said that my point about mempolicies needs more thought, I wasn't expecting that there would be no discussion -- at least _something_ that would say why we don't care about the mempolicy case. Lets get Andi involved here too. The motivation

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v5)

2014-05-30 Thread Andi Kleen
On Fri, May 30, 2014 at 08:50:56AM -0500, Christoph Lameter wrote: On Thu, 29 May 2014, David Rientjes wrote: When I said that my point about mempolicies needs more thought, I wasn't expecting that there would be no discussion -- at least _something_ that would say why we don't care about

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v4)

2014-05-30 Thread Marcelo Tosatti
On Fri, May 30, 2014 at 08:48:41AM -0500, Christoph Lameter wrote: On Thu, 29 May 2014, Andrew Morton wrote: if (!nodemask gfp_zone(gfp_mask) policy_zone) nodemask = node_states[N_ONLINE]; OK, thanks, I made the patch go away for now. And another issue is that

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v5)

2014-05-29 Thread David Rientjes
On Thu, 29 May 2014, Marcelo Tosatti wrote: > diff --git a/kernel/cpuset.c b/kernel/cpuset.c > index 3d54c41..3bbc23f 100644 > --- a/kernel/cpuset.c > +++ b/kernel/cpuset.c > @@ -2374,6 +2374,7 @@ static struct cpuset *nearest_hardwall_ancestor(struct > cpuset *cs) > * variable 'wait' is not

[PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v5)

2014-05-29 Thread Marcelo Tosatti
Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. Necessary for the following usecase: - driver which requires zone specific memory

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v4)

2014-05-29 Thread Andrew Morton
On Thu, 29 May 2014 16:01:55 -0700 (PDT) David Rientjes wrote: > There are still three issues with this, two of which are only minor and > one that needs more thought: > > (1) this doesn't affect only cpusets which the changelog indicates, it > also bypasses mempolicies for GFP_DMA and

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v4)

2014-05-29 Thread David Rientjes
On Thu, 29 May 2014, Marcelo Tosatti wrote: > Zone specific allocations, such as GFP_DMA32, should not be restricted > to cpusets allowed node list: the zones which such allocations demand > might be contained in particular nodes outside the cpuset node list. > > Necessary for the following

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v4)

2014-05-29 Thread Andrew Morton
On Thu, 29 May 2014 15:43:03 -0300 Marcelo Tosatti wrote: > > Zone specific allocations, such as GFP_DMA32, should not be restricted > to cpusets allowed node list: the zones which such allocations demand > might be contained in particular nodes outside the cpuset node list. > > Necessary for

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v3)

2014-05-29 Thread Marcelo Tosatti
On Wed, May 28, 2014 at 06:45:04PM -0500, Christoph Lameter wrote: Much cleaner, sent v4 with your suggestions. > Why call __alloc_pages_nodemask at all if you want to skip the node > handling? Punt to alloc_pages() - __alloc_pages_nodemask ignored GFP_DMA32 on older kernels, so the

[PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v4)

2014-05-29 Thread Marcelo Tosatti
Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. Necessary for the following usecase: - driver which requires zone specific memory

[PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v4)

2014-05-29 Thread Marcelo Tosatti
Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. Necessary for the following usecase: - driver which requires zone specific memory

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v3)

2014-05-29 Thread Marcelo Tosatti
On Wed, May 28, 2014 at 06:45:04PM -0500, Christoph Lameter wrote: snip Much cleaner, sent v4 with your suggestions. Why call __alloc_pages_nodemask at all if you want to skip the node handling? Punt to alloc_pages() - __alloc_pages_nodemask ignored GFP_DMA32 on older kernels, so the

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v4)

2014-05-29 Thread Andrew Morton
On Thu, 29 May 2014 15:43:03 -0300 Marcelo Tosatti mtosa...@redhat.com wrote: Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list.

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v4)

2014-05-29 Thread David Rientjes
On Thu, 29 May 2014, Marcelo Tosatti wrote: Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. Necessary for the following usecase:

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v4)

2014-05-29 Thread Andrew Morton
On Thu, 29 May 2014 16:01:55 -0700 (PDT) David Rientjes rient...@google.com wrote: There are still three issues with this, two of which are only minor and one that needs more thought: (1) this doesn't affect only cpusets which the changelog indicates, it also bypasses mempolicies

[PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v5)

2014-05-29 Thread Marcelo Tosatti
Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. Necessary for the following usecase: - driver which requires zone specific memory

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v5)

2014-05-29 Thread David Rientjes
On Thu, 29 May 2014, Marcelo Tosatti wrote: diff --git a/kernel/cpuset.c b/kernel/cpuset.c index 3d54c41..3bbc23f 100644 --- a/kernel/cpuset.c +++ b/kernel/cpuset.c @@ -2374,6 +2374,7 @@ static struct cpuset *nearest_hardwall_ancestor(struct cpuset *cs) * variable 'wait' is not set, and

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v3)

2014-05-28 Thread Christoph Lameter
On Wed, 28 May 2014, Marcelo Tosatti wrote: > diff --git a/mm/page_alloc.c b/mm/page_alloc.c > index 5dba293..dfea3dc 100644 > --- a/mm/page_alloc.c > +++ b/mm/page_alloc.c > @@ -2698,6 +2698,7 @@ __alloc_pages_nodemask(gfp_t gfp_mask, unsigned int > order, > unsigned int

[PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v3)

2014-05-28 Thread Marcelo Tosatti
Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. Necessary for the following usecase: - driver which requires zone specific memory

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v2)

2014-05-28 Thread Li Zefan
On 2014/5/27 2:53, Marcelo Tosatti wrote: > > Zone specific allocations, such as GFP_DMA32, should not be restricted > to cpusets allowed node list: the zones which such allocations demand > might be contained in particular nodes outside the cpuset node list. > > The alternative would be to not

[PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v3)

2014-05-28 Thread Marcelo Tosatti
Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. Necessary for the following usecase: - driver which requires zone specific memory

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v3)

2014-05-28 Thread Christoph Lameter
On Wed, 28 May 2014, Marcelo Tosatti wrote: diff --git a/mm/page_alloc.c b/mm/page_alloc.c index 5dba293..dfea3dc 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -2698,6 +2698,7 @@ __alloc_pages_nodemask(gfp_t gfp_mask, unsigned int order, unsigned int cpuset_mems_cookie;

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v2)

2014-05-28 Thread Li Zefan
On 2014/5/27 2:53, Marcelo Tosatti wrote: Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. The alternative would be to not

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-27 Thread Christoph Lameter
On Tue, 27 May 2014, Marcelo Tosatti wrote: > > > > Memory policies are only applied to a specific zone so this is not > > unprecedented. However, if a user wants to limit allocation to a specific > > node and there is no DMA memory there then may be that is a operator > > error? After all the

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-27 Thread Marcelo Tosatti
On Tue, May 27, 2014 at 11:53:52AM -0300, Marcelo Tosatti wrote: > On Tue, May 27, 2014 at 09:21:32AM -0500, Christoph Lameter wrote: > > On Fri, 23 May 2014, Marcelo Tosatti wrote: > > > > > Zone specific allocations, such as GFP_DMA32, should not be restricted > > > to cpusets allowed node

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-27 Thread Marcelo Tosatti
On Tue, May 27, 2014 at 09:21:32AM -0500, Christoph Lameter wrote: > On Fri, 23 May 2014, Marcelo Tosatti wrote: > > > Zone specific allocations, such as GFP_DMA32, should not be restricted > > to cpusets allowed node list: the zones which such allocations demand > > might be contained in

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-27 Thread Christoph Lameter
On Fri, 23 May 2014, Marcelo Tosatti wrote: > Zone specific allocations, such as GFP_DMA32, should not be restricted > to cpusets allowed node list: the zones which such allocations demand > might be contained in particular nodes outside the cpuset node list. > > The alternative would be to not

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-27 Thread Christoph Lameter
On Fri, 23 May 2014, Marcelo Tosatti wrote: Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. The alternative would be to not

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-27 Thread Marcelo Tosatti
On Tue, May 27, 2014 at 09:21:32AM -0500, Christoph Lameter wrote: On Fri, 23 May 2014, Marcelo Tosatti wrote: Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-27 Thread Marcelo Tosatti
On Tue, May 27, 2014 at 11:53:52AM -0300, Marcelo Tosatti wrote: On Tue, May 27, 2014 at 09:21:32AM -0500, Christoph Lameter wrote: On Fri, 23 May 2014, Marcelo Tosatti wrote: Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-27 Thread Christoph Lameter
On Tue, 27 May 2014, Marcelo Tosatti wrote: Memory policies are only applied to a specific zone so this is not unprecedented. However, if a user wants to limit allocation to a specific node and there is no DMA memory there then may be that is a operator error? After all the application

[PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v2)

2014-05-26 Thread Marcelo Tosatti
Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. The alternative would be to not perform such allocations from applications which are

[PATCH] page_alloc: skip cpuset enforcement for lower zone allocations (v2)

2014-05-26 Thread Marcelo Tosatti
Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. The alternative would be to not perform such allocations from applications which are

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-23 Thread Marcelo Tosatti
On Fri, May 23, 2014 at 01:51:12PM -0700, David Rientjes wrote: > On Fri, 23 May 2014, Marcelo Tosatti wrote: > > > Zone specific allocations, such as GFP_DMA32, should not be restricted > > to cpusets allowed node list: the zones which such allocations demand > > might be contained in particular

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-23 Thread David Rientjes
On Fri, 23 May 2014, Marcelo Tosatti wrote: > Zone specific allocations, such as GFP_DMA32, should not be restricted > to cpusets allowed node list: the zones which such allocations demand > might be contained in particular nodes outside the cpuset node list. > > The alternative would be to not

[PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-23 Thread Marcelo Tosatti
Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. The alternative would be to not perform such allocations from applications which are

[PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-23 Thread Marcelo Tosatti
Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. The alternative would be to not perform such allocations from applications which are

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-23 Thread David Rientjes
On Fri, 23 May 2014, Marcelo Tosatti wrote: Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes outside the cpuset node list. The alternative would be to not

Re: [PATCH] page_alloc: skip cpuset enforcement for lower zone allocations

2014-05-23 Thread Marcelo Tosatti
On Fri, May 23, 2014 at 01:51:12PM -0700, David Rientjes wrote: On Fri, 23 May 2014, Marcelo Tosatti wrote: Zone specific allocations, such as GFP_DMA32, should not be restricted to cpusets allowed node list: the zones which such allocations demand might be contained in particular nodes