summaryrefslogtreecommitdiffstats
path: root/mm/hugetlb.c
diff options
context:
space:
mode:
authorDavid Rientjes2014-08-07 01:07:54 +0200
committerLinus Torvalds2014-08-07 03:01:21 +0200
commit8fe780484d2674eec27e12bb29c07d3e98a7ad21 (patch)
treeb7cefa9ab0a94bd3582b6c98ca0b3e0909a119c2 /mm/hugetlb.c
parentmm, oom: rename zonelist locking functions (diff)
downloadkernel-qcow2-linux-8fe780484d2674eec27e12bb29c07d3e98a7ad21.tar.gz
kernel-qcow2-linux-8fe780484d2674eec27e12bb29c07d3e98a7ad21.tar.xz
kernel-qcow2-linux-8fe780484d2674eec27e12bb29c07d3e98a7ad21.zip
mm, thp: restructure thp avoidance of light synchronous migration
__GFP_NO_KSWAPD, once the way to determine if an allocation was for thp or not, has gained more users. Their use is not necessarily wrong, they are trying to do a memory allocation that can easily fail without disturbing kswapd, so the bit has gained additional usecases. This restructures the check to determine whether MIGRATE_SYNC_LIGHT should be used for memory compaction in the page allocator. Rather than testing solely for __GFP_NO_KSWAPD, test for all bits that must be set for thp allocations. This also moves the check to be done only after the page allocator is aborted for deferred or contended memory compaction since setting migration_mode for this case is pointless. Signed-off-by: David Rientjes <rientjes@google.com> Cc: Mel Gorman <mgorman@suse.de> Cc: Rik van Riel <riel@redhat.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/hugetlb.c')
0 files changed, 0 insertions, 0 deletions