[Devel] [PATCH rh7 4/7] mm/memcg: make __memcg_activate_kmem() to actually activate kmem
Andrey Ryabinin
aryabinin at virtuozzo.com
Fri Mar 31 06:51:08 PDT 2017
Commit 5e049077fce3 ("ms/memcg: rework memcg_update_kmem_limit synchronization")
which is actually reapplied after rebase commit d0abbfb74b16
forget to set active bit on kmem_account_flags.
This leaves kmem accounting disabled.
Fix that by calling memcg_kmem_set_active(memcg) from __memcg_activate_kmem();
https://jira.sw.ru/browse/PSBM-62827
Signed-off-by: Andrey Ryabinin <aryabinin at virtuozzo.com>
---
mm/memcontrol.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/mm/memcontrol.c b/mm/memcontrol.c
index 13d4205..bc72a26 100644
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@ -4351,6 +4351,8 @@ static int __memcg_activate_kmem(struct mem_cgroup *memcg,
* patched.
*/
memcg->kmemcg_id = memcg_id;
+ set_bit(KMEM_ACCOUNTED_ACTIVE, &memcg->kmem_account_flags);
+ set_bit(KMEM_ACCOUNTED_ACTIVATED, &memcg->kmem_account_flags);
out:
return err;
}
--
2.10.2
More information about the Devel
mailing list