4 #include <linux/jump_label.h>
5 #include <linux/psi_types.h>
6 #include <linux/sched.h>
13 extern struct static_key_false psi_disabled;
17 void psi_task_change(struct task_struct *task, int clear, int set);
19 void psi_memstall_tick(struct task_struct *task, int cpu);
20 void psi_memstall_enter(unsigned long *flags);
21 void psi_memstall_leave(unsigned long *flags);
23 int psi_show(struct seq_file *s, struct psi_group *group, enum psi_res res);
26 int psi_cgroup_alloc(struct cgroup *cgrp);
27 void psi_cgroup_free(struct cgroup *cgrp);
28 void cgroup_move_task(struct task_struct *p, struct css_set *to);
31 #else /* CONFIG_PSI */
33 static inline void psi_init(void) {}
35 static inline void psi_memstall_enter(unsigned long *flags) {}
36 static inline void psi_memstall_leave(unsigned long *flags) {}
39 static inline int psi_cgroup_alloc(struct cgroup *cgrp)
43 static inline void psi_cgroup_free(struct cgroup *cgrp)
46 static inline void cgroup_move_task(struct task_struct *p, struct css_set *to)
48 rcu_assign_pointer(p->cgroups, to);
52 #endif /* CONFIG_PSI */
54 #endif /* _LINUX_PSI_H */