[PATCH] memcg: check that kmem_cache has memcg_params before accessing it

2013-08-27 Thread Andrey Vagin
If the system had a few memory groups and all of them were destroyed, memcg_limited_groups_array_size has non-zero value, but all new caches are created without memcg_params, because memcg_kmem_enabled() returns false. We try to enumirate child caches in a few places and all of them are

[PATCH] memcg: check that kmem_cache has memcg_params before accessing it

2013-08-27 Thread Andrey Vagin
If the system had a few memory groups and all of them were destroyed, memcg_limited_groups_array_size has non-zero value, but all new caches are created without memcg_params, because memcg_kmem_enabled() returns false. We try to enumirate child caches in a few places and all of them are