From a18ecf38522ef84f9c433aa65c17500463e0c98c Mon Sep 17 00:00:00 2001 From: Nico Pache Date: Wed, 2 Nov 2022 08:54:50 -0600 Subject: [PATCH] mm: compaction: use helper isolation_suitable() commit 4af12d04e71c2d0d961c4921602e577d6cc6010e Author: Miaohe Lin Date: Thu Apr 28 23:16:06 2022 -0700 mm: compaction: use helper isolation_suitable() Use helper isolation_suitable() to check whether page is suitable to isolate to simplify the code. Minor readability improvement. Link: https://lkml.kernel.org/r/20220322110750.60311-1-linmiaohe@huawei.com Signed-off-by: Miaohe Lin Reviewed-by: Andrew Morton Reviewed-by: Wei Yang Signed-off-by: Andrew Morton Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2089498 Signed-off-by: Nico Pache --- mm/compaction.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/compaction.c b/mm/compaction.c index de42b8e48758..02b8d903c691 100644 --- a/mm/compaction.c +++ b/mm/compaction.c @@ -899,7 +899,7 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn, * not falsely conclude that the block should be skipped. */ if (!valid_page && IS_ALIGNED(low_pfn, pageblock_nr_pages)) { - if (!cc->ignore_skip_hint && get_pageblock_skip(page)) { + if (!isolation_suitable(cc, page)) { low_pfn = end_pfn; page = NULL; goto isolate_abort;