Re: [RFC][PATCH 3/9] mm: page->pfmemalloc only used by slab/skb

From: Kirill A. Shutemov
Date: Wed Jan 15 2014 - 19:17:07 EST


On Tue, Jan 14, 2014 at 10:00:51AM -0800, Dave Hansen wrote:
>
> From: Dave Hansen <dave.hansen@xxxxxxxxxxxxxxx>
>
> page->pfmemalloc does not deserve a spot in 'struct page'. It is
> only used transiently _just_ after a page leaves the buddy
> allocator.
>
> Instead of declaring a union, we move its functionality behind a
> few quick accessor functions. This way we could also much more
> easily audit that it is being used correctly in debugging
> scenarios. For instance, we could store a magic number in there
> which could never get reused as a page->index and check that the
> magic number exists in page_pfmemalloc().
>
> Signed-off-by: Dave Hansen <dave.hansen@xxxxxxxxxxxxxxx>

Acked-by: Kirill A. Shutemov <kirill.shutemov@xxxxxxxxxxxxxxx>

--
Kirill A. Shutemov
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/