Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit cd59564d authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "mm: fix kcompactd hang during memory offlining"

parents 7e6c1371 50f8e4e2
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -1772,7 +1772,7 @@ void compaction_unregister_node(struct node *node)

static inline bool kcompactd_work_requested(pg_data_t *pgdat)
{
	return pgdat->kcompactd_max_order > 0;
	return pgdat->kcompactd_max_order > 0 || kthread_should_stop();
}

static bool kcompactd_node_suitable(pg_data_t *pgdat)
@@ -1836,6 +1836,8 @@ static void kcompactd_do_work(pg_data_t *pgdat)
		INIT_LIST_HEAD(&cc.freepages);
		INIT_LIST_HEAD(&cc.migratepages);

		if (kthread_should_stop())
			return;
		status = compact_zone(zone, &cc);

		if (zone_watermark_ok(zone, cc.order, low_wmark_pages(zone),