Lines Matching refs:hugetlb_cgroup
30 static struct hugetlb_cgroup *root_h_cgroup __read_mostly;
33 __hugetlb_cgroup_counter_from_cgroup(struct hugetlb_cgroup *h_cg, int idx, in __hugetlb_cgroup_counter_from_cgroup()
42 hugetlb_cgroup_counter_from_cgroup(struct hugetlb_cgroup *h_cg, int idx) in hugetlb_cgroup_counter_from_cgroup()
48 hugetlb_cgroup_counter_from_cgroup_rsvd(struct hugetlb_cgroup *h_cg, int idx) in hugetlb_cgroup_counter_from_cgroup_rsvd()
54 struct hugetlb_cgroup *hugetlb_cgroup_from_css(struct cgroup_subsys_state *s) in hugetlb_cgroup_from_css()
56 return s ? container_of(s, struct hugetlb_cgroup, css) : NULL; in hugetlb_cgroup_from_css()
60 struct hugetlb_cgroup *hugetlb_cgroup_from_task(struct task_struct *task) in hugetlb_cgroup_from_task()
65 static inline bool hugetlb_cgroup_is_root(struct hugetlb_cgroup *h_cg) in hugetlb_cgroup_is_root()
70 static inline struct hugetlb_cgroup *
71 parent_hugetlb_cgroup(struct hugetlb_cgroup *h_cg) in parent_hugetlb_cgroup()
76 static inline bool hugetlb_cgroup_have_usage(struct hugetlb_cgroup *h_cg) in hugetlb_cgroup_have_usage()
88 static void hugetlb_cgroup_init(struct hugetlb_cgroup *h_cgroup, in hugetlb_cgroup_init()
89 struct hugetlb_cgroup *parent_h_cgroup) in hugetlb_cgroup_init()
126 static void hugetlb_cgroup_free(struct hugetlb_cgroup *h_cgroup) in hugetlb_cgroup_free()
138 struct hugetlb_cgroup *parent_h_cgroup = hugetlb_cgroup_from_css(parent_css); in hugetlb_cgroup_css_alloc()
139 struct hugetlb_cgroup *h_cgroup; in hugetlb_cgroup_css_alloc()
187 static void hugetlb_cgroup_move_parent(int idx, struct hugetlb_cgroup *h_cg, in hugetlb_cgroup_move_parent()
192 struct hugetlb_cgroup *page_hcg; in hugetlb_cgroup_move_parent()
193 struct hugetlb_cgroup *parent = parent_hugetlb_cgroup(h_cg); in hugetlb_cgroup_move_parent()
225 struct hugetlb_cgroup *h_cg = hugetlb_cgroup_from_css(css); in hugetlb_cgroup_css_offline()
241 static inline void hugetlb_event(struct hugetlb_cgroup *hugetlb, int idx, in hugetlb_event()
255 struct hugetlb_cgroup **ptr, in __hugetlb_cgroup_charge_cgroup()
260 struct hugetlb_cgroup *h_cg = NULL; in __hugetlb_cgroup_charge_cgroup()
298 struct hugetlb_cgroup **ptr) in hugetlb_cgroup_charge_cgroup()
304 struct hugetlb_cgroup **ptr) in hugetlb_cgroup_charge_cgroup_rsvd()
311 struct hugetlb_cgroup *h_cg, in __hugetlb_cgroup_commit_charge()
332 struct hugetlb_cgroup *h_cg, in hugetlb_cgroup_commit_charge()
339 struct hugetlb_cgroup *h_cg, in hugetlb_cgroup_commit_charge_rsvd()
351 struct hugetlb_cgroup *h_cg; in __hugetlb_cgroup_uncharge_page()
393 struct hugetlb_cgroup *h_cg, in __hugetlb_cgroup_uncharge_cgroup()
411 struct hugetlb_cgroup *h_cg) in hugetlb_cgroup_uncharge_cgroup()
417 struct hugetlb_cgroup *h_cg) in hugetlb_cgroup_uncharge_cgroup_rsvd()
472 struct hugetlb_cgroup *h_cg = hugetlb_cgroup_from_css(seq_css(seq)); in hugetlb_cgroup_read_numa_stat()
524 struct hugetlb_cgroup *h_cg = hugetlb_cgroup_from_css(css); in hugetlb_cgroup_read_u64()
558 struct hugetlb_cgroup *h_cg = hugetlb_cgroup_from_css(seq_css(seq)); in hugetlb_cgroup_read_u64_max()
599 struct hugetlb_cgroup *h_cg = hugetlb_cgroup_from_css(of_css(of)); in hugetlb_cgroup_write()
648 struct hugetlb_cgroup *h_cg = hugetlb_cgroup_from_css(of_css(of)); in hugetlb_cgroup_reset()
689 struct hugetlb_cgroup *h_cg = hugetlb_cgroup_from_css(seq_css(seq)); in __hugetlb_events_show()
757 cft->file_offset = offsetof(struct hugetlb_cgroup, events_file[idx]); in __hugetlb_cgroup_file_dfl_init()
765 cft->file_offset = offsetof(struct hugetlb_cgroup, in __hugetlb_cgroup_file_dfl_init()
888 struct hugetlb_cgroup *h_cg; in hugetlb_cgroup_migrate()
889 struct hugetlb_cgroup *h_cg_rsvd; in hugetlb_cgroup_migrate()