Commit 8df4e28c authored by Kemeng Shi's avatar Kemeng Shi Committed by Andrew Morton
Browse files

mm/compaction: remove repeat compact_blockskip_flush check in reset_isolation_suitable

We have compact_blockskip_flush check in __reset_isolation_suitable, just
remove repeat check before __reset_isolation_suitable in
compact_blockskip_flush.

Link: https://lkml.kernel.org/r/20230901155141.249860-5-shikemeng@huaweicloud.com


Signed-off-by: default avatarKemeng Shi <shikemeng@huaweicloud.com>
Reviewed-by: default avatarBaolin Wang <baolin.wang@linux.alibaba.com>
Acked-by: default avatarMel Gorman <mgorman@techsingularity.net>
Cc: David Hildenbrand <david@redhat.com>
Cc: Matthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent 3da0272a
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -382,6 +382,7 @@ static void __reset_isolation_suitable(struct zone *zone)
	bool source_set = false;
	bool free_set = false;

	/* Only flush if a full compaction finished recently */
	if (!zone->compact_blockskip_flush)
		return;

@@ -434,8 +435,6 @@ void reset_isolation_suitable(pg_data_t *pgdat)
		if (!populated_zone(zone))
			continue;

		/* Only flush if a full compaction finished recently */
		if (zone->compact_blockskip_flush)
		__reset_isolation_suitable(zone);
	}
}