Lines Matching refs:children
292 char *children[4] = {NULL}; in test_memcg_protection() local
343 for (i = 0; i < ARRAY_SIZE(children); i++) { in test_memcg_protection()
344 children[i] = cg_name_indexed(parent[1], "child_memcg", i); in test_memcg_protection()
345 if (!children[i]) in test_memcg_protection()
348 if (cg_create(children[i])) in test_memcg_protection()
354 cg_run_nowait(children[i], alloc_pagecache_50M_noexit, in test_memcg_protection()
360 if (cg_write(children[0], attribute, "75M")) in test_memcg_protection()
362 if (cg_write(children[1], attribute, "25M")) in test_memcg_protection()
364 if (cg_write(children[2], attribute, "0")) in test_memcg_protection()
366 if (cg_write(children[3], attribute, "500M")) in test_memcg_protection()
383 for (i = 0; i < ARRAY_SIZE(children); i++) in test_memcg_protection()
384 c[i] = cg_read_long(children[i], "memory.current"); in test_memcg_protection()
408 if (!reclaim_until(children[0], MB(10))) in test_memcg_protection()
416 for (i = 0; i < ARRAY_SIZE(children); i++) { in test_memcg_protection()
420 oom = cg_read_key_long(children[i], "memory.events", "oom "); in test_memcg_protection()
421 low = cg_read_key_long(children[i], "memory.events", "low "); in test_memcg_protection()
435 for (i = ARRAY_SIZE(children) - 1; i >= 0; i--) { in test_memcg_protection()
436 if (!children[i]) in test_memcg_protection()
439 cg_destroy(children[i]); in test_memcg_protection()
440 free(children[i]); in test_memcg_protection()