From: Christoph Lameter Date: Wed, 16 May 2007 06:57:09 +0000 (-0700) Subject: Fix: find_or_create_page skips cpuset memory spreading. X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=43c0f3d25c602dc96b201ed81ffda0bc600ff969;p=GitHub%2Fmt8127%2Fandroid_kernel_alcatel_ttab.git Fix: find_or_create_page skips cpuset memory spreading. We call alloc_page where we should be calling __page_cache_alloc. __page_cache_alloc performs cpuset memory spreading. alloc_page does not. There is no reason that pages allocated via find_or_create should be exempt. Signed-off-by: Christoph Lameter Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/mm/filemap.c b/mm/filemap.c index 7b48b2ad00e7..edb1b0b5cc8d 100644 --- a/mm/filemap.c +++ b/mm/filemap.c @@ -670,7 +670,8 @@ repeat: page = find_lock_page(mapping, index); if (!page) { if (!cached_page) { - cached_page = alloc_page(gfp_mask); + cached_page = + __page_cache_alloc(gfp_mask); if (!cached_page) return NULL; }