diff options
author | Liam Mark <lmark@codeaurora.org> | 2012-11-27 18:49:58 -0800 |
---|---|---|
committer | David Keitel <dkeitel@codeaurora.org> | 2016-03-22 11:03:38 -0700 |
commit | 78ec19c5f9a177a11042c5bcd5387ed595e04e1d (patch) | |
tree | 28136353f8f681c62ff72272c99b28820d957597 /mm/page_alloc.c | |
parent | 81f620153455f246c124fb2d9ef5559e714e3889 (diff) |
mm: split_free_page ignore memory watermarks for CMA
Memory watermarks were sometimes preventing CMA allocations
in low memory.
Change-Id: I550ec987cbd6bc6dadd72b4a764df20cd0758479
Signed-off-by: Liam Mark <lmark@codeaurora.org>
Diffstat (limited to 'mm/page_alloc.c')
-rw-r--r-- | mm/page_alloc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/mm/page_alloc.c b/mm/page_alloc.c index 896c6c63fe58..5e7050897ec4 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -2146,7 +2146,8 @@ int __isolate_free_page(struct page *page, unsigned int order) if (!is_migrate_isolate(mt)) { /* Obey watermarks as if the page was being allocated */ watermark = low_wmark_pages(zone) + (1 << order); - if (!zone_watermark_ok(zone, 0, watermark, 0, 0)) + if (!is_migrate_cma(mt) && + !zone_watermark_ok(zone, 0, watermark, 0, 0)) return 0; __mod_zone_freepage_state(zone, -(1UL << order), mt); |