Lines Matching refs:cgroup
2 * ns_cgroup.c - namespace cgroup subsystem
8 #include <linux/cgroup.h>
21 struct cgroup *cgroup)
23 return container_of(cgroup_subsys_state(cgroup, ns_subsys_id),
37 * 1. you can only enter a cgroup which is a descendant of your current
38 * cgroup
39 * 2. you can only place another process into a cgroup if
41 * b. your cgroup is an ancestor of task's destination cgroup
42 * (hence either you are in the same cgroup as task, or in an
43 * ancestor cgroup thereof)
45 static int ns_can_attach(struct cgroup_subsys *ss, struct cgroup *new_cgroup,
75 * Rules: you can only create a cgroup if
77 * 2. the target cgroup is a descendant of your own cgroup
80 struct cgroup *cgroup)
86 if (!cgroup_is_descendant(cgroup, current))
96 struct cgroup *cgroup)
100 ns_cgroup = cgroup_to_ns(cgroup);