diff options
author | Rik van Riel <riel@redhat.com> | 2012-03-21 19:33:52 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-03-21 20:54:56 -0400 |
commit | aff622495c9a0b56148192e53bdec539f5e147f2 (patch) | |
tree | 78f6400d8b6bec3279483006a0e9543e47aa833e /include/linux/mmzone.h | |
parent | 7be62de99adcab4449d416977b4274985c5fe023 (diff) |
vmscan: only defer compaction for failed order and higher
Currently a failed order-9 (transparent hugepage) compaction can lead to
memory compaction being temporarily disabled for a memory zone. Even if
we only need compaction for an order 2 allocation, eg. for jumbo frames
networking.
The fix is relatively straightforward: keep track of the highest order at
which compaction is succeeding, and only defer compaction for orders at
which compaction is failing.
Signed-off-by: Rik van Riel <riel@redhat.com>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Acked-by: Mel Gorman <mel@csn.ul.ie>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: Minchan Kim <minchan.kim@gmail.com>
Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Cc: Hillf Danton <dhillf@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/mmzone.h')
-rw-r--r-- | include/linux/mmzone.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index 650ba2fb3301..dff711509661 100644 --- a/include/linux/mmzone.h +++ b/include/linux/mmzone.h | |||
@@ -365,6 +365,7 @@ struct zone { | |||
365 | */ | 365 | */ |
366 | unsigned int compact_considered; | 366 | unsigned int compact_considered; |
367 | unsigned int compact_defer_shift; | 367 | unsigned int compact_defer_shift; |
368 | int compact_order_failed; | ||
368 | #endif | 369 | #endif |
369 | 370 | ||
370 | ZONE_PADDING(_pad1_) | 371 | ZONE_PADDING(_pad1_) |