]> git.baikalelectronics.ru Git - kernel.git/commit
mm: compaction: capture a suitable high-order page immediately when it is made available
authorMel Gorman <mgorman@suse.de>
Mon, 8 Oct 2012 23:29:12 +0000 (16:29 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 9 Oct 2012 07:22:21 +0000 (16:22 +0900)
commitbd7251b3e87cfe88f493b29b6982fe83c7c958a5
tree5e72498f44d4fcae18f29eb87dd05a849a7a23c9
parent90c8af4d97a267b5674d5a509b02f4f571d66b6c
mm: compaction: capture a suitable high-order page immediately when it is made available

While compaction is migrating pages to free up large contiguous blocks
for allocation it races with other allocation requests that may steal
these blocks or break them up.  This patch alters direct compaction to
capture a suitable free page as soon as it becomes available to reduce
this race.  It uses similar logic to split_free_page() to ensure that
watermarks are still obeyed.

Signed-off-by: Mel Gorman <mgorman@suse.de>
Reviewed-by: Rik van Riel <riel@redhat.com>
Reviewed-by: Minchan Kim <minchan@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
include/linux/compaction.h
include/linux/mm.h
mm/compaction.c
mm/internal.h
mm/page_alloc.c