diff options
| author | Linux Build Service Account <lnxbuild@localhost> | 2017-02-25 01:09:40 -0800 |
|---|---|---|
| committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2017-02-25 01:09:39 -0800 |
| commit | fedfb30bbd667643fe32d0c07b478849f0c846c0 (patch) | |
| tree | a75450c68b6bb5b312cdb47eb858ec433d629710 /mm/compaction.c | |
| parent | 053c4faad00241374c42e4dc5d20bc0506122ea8 (diff) | |
| parent | 18be75139f2c3f8ecd151919239f6e129152ff2f (diff) | |
Merge "mm, kswapd: replace kswapd compaction with waking up kcompactd"
Diffstat (limited to 'mm/compaction.c')
| -rw-r--r-- | mm/compaction.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/mm/compaction.c b/mm/compaction.c index 538405d31c7f..a5f1eba6ff27 100644 --- a/mm/compaction.c +++ b/mm/compaction.c @@ -1226,11 +1226,11 @@ static int __compact_finished(struct zone *zone, struct compact_control *cc, /* * Mark that the PG_migrate_skip information should be cleared - * by kswapd when it goes to sleep. kswapd does not set the + * by kswapd when it goes to sleep. kcompactd does not set the * flag itself as the decision to be clear should be directly * based on an allocation request. */ - if (!current_is_kswapd()) + if (cc->direct_compaction) zone->compact_blockskip_flush = true; return COMPACT_COMPLETE; @@ -1373,10 +1373,9 @@ static int compact_zone(struct zone *zone, struct compact_control *cc) /* * Clear pageblock skip if there were failures recently and compaction - * is about to be retried after being deferred. kswapd does not do - * this reset as it'll reset the cached information when going to sleep. + * is about to be retried after being deferred. */ - if (compaction_restarting(zone, cc->order) && !current_is_kswapd()) + if (compaction_restarting(zone, cc->order)) __reset_isolation_suitable(zone); /* @@ -1512,6 +1511,7 @@ static unsigned long compact_zone_order(struct zone *zone, int order, .mode = mode, .alloc_flags = alloc_flags, .classzone_idx = classzone_idx, + .direct_compaction = true, }; INIT_LIST_HEAD(&cc.freepages); INIT_LIST_HEAD(&cc.migratepages); |
