[Devel] [PATCH rh7 1/2] mm/vmscan: shrink slabs from offlined cgroups.

Andrey Ryabinin aryabinin at virtuozzo.com
Mon Apr 23 16:00:45 MSK 2018


Currently shrink_slab() skips offlined cgroups during per-memcg reclaim.
So only global reclaim can shrink slabs from offlined cgroups.
This doesn't make any sense, we should allow reclaiming offlined
cgroups, otherwise we can't destroy them (kmem pins memgc).

https://jira.sw.ru/browse/PSBM-83628
Signed-off-by: Andrey Ryabinin <aryabinin at virtuozzo.com>
---
 mm/vmscan.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/mm/vmscan.c b/mm/vmscan.c
index 4922f734cdb4..aefa4bc33062 100644
--- a/mm/vmscan.c
+++ b/mm/vmscan.c
@@ -395,9 +395,6 @@ static unsigned long shrink_slab(gfp_t gfp_mask, int nid,
 	struct shrinker *shrinker;
 	unsigned long freed = 0;
 
-	if (memcg && !memcg_kmem_is_active(memcg))
-		return 0;
-
 	if (unlikely(test_tsk_thread_flag(current, TIF_MEMDIE)))
 		return 0;
 
-- 
2.16.1



More information about the Devel mailing list