Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph...
[firefly-linux-kernel-4.4.55.git] / mm / compaction.c
index 3a91a2ea3d343d5bb22fdc1a5e67660a133de5e0..b48c5259ea33dfed9e4c08c956d8e30a36480c42 100644 (file)
@@ -523,7 +523,10 @@ isolate_migratepages_range(struct zone *zone, struct compact_control *cc,
                if (!isolation_suitable(cc, page))
                        goto next_pageblock;
 
-               /* Skip if free */
+               /*
+                * Skip if free. page_order cannot be used without zone->lock
+                * as nothing prevents parallel allocations or buddy merging.
+                */
                if (PageBuddy(page))
                        continue;
 
@@ -601,7 +604,7 @@ isolate_migratepages_range(struct zone *zone, struct compact_control *cc,
                if (__isolate_lru_page(page, mode) != 0)
                        continue;
 
-               VM_BUG_ON(PageTransCompound(page));
+               VM_BUG_ON_PAGE(PageTransCompound(page), page);
 
                /* Successfully isolated */
                cc->finished_update_migrate = true;