struct simple_xattrs xattrs;
};
--/*
- * cgroup_event represents events which userspace want to receive.
- * CSS ID -- ID per subsys's Cgroup Subsys State(CSS). used only when
- * cgroup_subsys->use_id != 0.
-- */
- struct cgroup_event {
-#define CSS_ID_MAX (65535)
-struct css_id {
-- /*
- * css which the event belongs to.
- * The css to which this ID points. This pointer is set to valid value
- * after cgroup is populated. If cgroup is removed, this will be NULL.
- * This pointer is expected to be RCU-safe because destroy()
- * is called after synchronize_rcu(). But for safe use, css_tryget()
- * should be used for avoiding race.
-- */
- struct cgroup_subsys_state *css;
- struct cgroup_subsys_state __rcu *css;
-- /*
- * Control file which the event associated.
- * ID of this css.
-- */
- struct cftype *cft;
- unsigned short id;
-- /*
- * eventfd to signal userspace about the event.
- * Depth in hierarchy which this ID belongs to.
-- */
- struct eventfd_ctx *eventfd;
- unsigned short depth;
-- /*
- * Each of these stored in a list by the cgroup.
- * ID is freed by RCU. (and lookup routine is RCU safe.)
-- */
- struct list_head list;
- struct rcu_head rcu_head;
-- /*
- * All fields below needed to unregister event when
- * userspace closes eventfd.
- * Hierarchy of CSS ID belongs to.
-- */
- poll_table pt;
- wait_queue_head_t *wqh;
- wait_queue_t wait;
- struct work_struct remove;
- unsigned short stack[0]; /* Array of Length (depth+1) */
--};
--
/* The list of hierarchy roots */
static LIST_HEAD(cgroup_roots);