diff --git a/include/linux/init_task.h b/include/linux/init_task.h index f6841c19c913ef911b37769f4ececa9ceac3c86e..91d9049f003938a77002d76f8a2f0b3313437294 100644 --- a/include/linux/init_task.h +++ b/include/linux/init_task.h @@ -151,8 +151,6 @@ extern struct group_info init_groups; extern struct cred init_cred; -extern struct task_group root_task_group; - #ifdef CONFIG_CGROUP_SCHED # define INIT_CGROUP_SCHED(tsk) \ .sched_task_group = &root_task_group, diff --git a/include/linux/sched.h b/include/linux/sched.h index af9590c8bfb0f39718f16c4fc2d4f3f9275e54f2..4934733bd6cb7d57cc5d9b09daa9c65e93b20334 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h @@ -1707,10 +1707,6 @@ static inline void set_task_cpu(struct task_struct *p, unsigned int cpu) extern long sched_setaffinity(pid_t pid, const struct cpumask *new_mask); extern long sched_getaffinity(pid_t pid, struct cpumask *mask); -#ifdef CONFIG_CGROUP_SCHED -extern struct task_group root_task_group; -#endif /* CONFIG_CGROUP_SCHED */ - extern int task_can_switch_user(struct user_struct *up, struct task_struct *tsk); diff --git a/include/linux/sched/autogroup.h b/include/linux/sched/autogroup.h index 586bdf37330dde37630e0d971bb4e1fd8458ffd4..fd6855548d0c7f3cb66e62173a65a2ae8e6d4ade 100644 --- a/include/linux/sched/autogroup.h +++ b/include/linux/sched/autogroup.h @@ -4,6 +4,7 @@ #include struct signal_struct; +struct task_group; struct seq_file; #ifdef CONFIG_SCHED_AUTOGROUP @@ -24,4 +25,8 @@ static inline void sched_autogroup_exit(struct signal_struct *sig) { } static inline void sched_autogroup_exit_task(struct task_struct *p) { } #endif +#ifdef CONFIG_CGROUP_SCHED +extern struct task_group root_task_group; +#endif /* CONFIG_CGROUP_SCHED */ + #endif /* _LINUX_SCHED_AUTOGROUP_H */