Re: [PATCH v2 01/15] slab: correct pfmemalloc check

2013-10-16 Thread Joonsoo Kim
On Wed, Oct 16, 2013 at 03:27:54PM +, Christoph Lameter wrote: > On Wed, 16 Oct 2013, Joonsoo Kim wrote: > > > --- a/mm/slab.c > > +++ b/mm/slab.c > > @@ -930,7 +930,8 @@ static void *__ac_put_obj(struct kmem_cache *cachep, > > struct array_cache *ac, > > { > > if (unlikely(pfmemalloc_ac

Re: [PATCH v2 01/15] slab: correct pfmemalloc check

2013-10-16 Thread Christoph Lameter
On Wed, 16 Oct 2013, Joonsoo Kim wrote: > --- a/mm/slab.c > +++ b/mm/slab.c > @@ -930,7 +930,8 @@ static void *__ac_put_obj(struct kmem_cache *cachep, > struct array_cache *ac, > { > if (unlikely(pfmemalloc_active)) { > /* Some pfmemalloc slabs exist, check if this is one */

[PATCH v2 01/15] slab: correct pfmemalloc check

2013-10-16 Thread Joonsoo Kim
We checked pfmemalloc by slab unit, not page unit. You can see this in is_slab_pfmemalloc(). So other pages don't need to be set/cleared pfmemalloc. And, therefore we should check pfmemalloc in page flag of first page, but current implementation don't do that. virt_to_head_page(obj) just return 's