]> git.karo-electronics.de Git - karo-tx-linux.git/commit
mm, memcg: sync allocation and memcg charge gfp flags for thp fix fix
authorDavid Rientjes <rientjes@google.com>
Tue, 7 Apr 2015 23:44:28 +0000 (09:44 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 7 Apr 2015 23:44:28 +0000 (09:44 +1000)
commit72d3eb0037fe6b21701df7157142c61db76e5cc0
tree608c2289270213b0b8e57c13a77b2f5c70b85dc6
parentf5d96e82d3cf9149f505364152736fd6e4fa247b
mm, memcg: sync allocation and memcg charge gfp flags for thp fix fix

"mm, memcg: sync allocation and memcg charge gfp flags for THP" in -mm
introduces a formal to pass the gfp mask for khugepaged's hugepage
allocation.  This is just too ugly to live.

alloc_hugepage_gfpmask() cannot differ between NUMA and UMA configs by
anything in GFP_RECLAIM_MASK, which is the only thing that matters for
memcg reclaim, so just determine the gfp flags once in
collapse_huge_page() and avoid the complexity.

Signed-off-by: David Rientjes <rientjes@google.com>
Acked-by: Michal Hocko <mhocko@suse.cz>
Acked-by: Vlastimil Babka <vbabka@suse.cz>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/huge_memory.c