diff options
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/sched/auto_group.c | 6 | ||||
-rw-r--r-- | kernel/sched/core.c | 6 |
2 files changed, 7 insertions, 5 deletions
diff --git a/kernel/sched/auto_group.c b/kernel/sched/auto_group.c index 8a2e230fb86a..eae160dd669d 100644 --- a/kernel/sched/auto_group.c +++ b/kernel/sched/auto_group.c | |||
@@ -87,8 +87,7 @@ static inline struct autogroup *autogroup_create(void) | |||
87 | * so we don't have to move tasks around upon policy change, | 87 | * so we don't have to move tasks around upon policy change, |
88 | * or flail around trying to allocate bandwidth on the fly. | 88 | * or flail around trying to allocate bandwidth on the fly. |
89 | * A bandwidth exception in __sched_setscheduler() allows | 89 | * A bandwidth exception in __sched_setscheduler() allows |
90 | * the policy change to proceed. Thereafter, task_group() | 90 | * the policy change to proceed. |
91 | * returns &root_task_group, so zero bandwidth is required. | ||
92 | */ | 91 | */ |
93 | free_rt_sched_group(tg); | 92 | free_rt_sched_group(tg); |
94 | tg->rt_se = root_task_group.rt_se; | 93 | tg->rt_se = root_task_group.rt_se; |
@@ -115,9 +114,6 @@ bool task_wants_autogroup(struct task_struct *p, struct task_group *tg) | |||
115 | if (tg != &root_task_group) | 114 | if (tg != &root_task_group) |
116 | return false; | 115 | return false; |
117 | 116 | ||
118 | if (p->sched_class != &fair_sched_class) | ||
119 | return false; | ||
120 | |||
121 | /* | 117 | /* |
122 | * We can only assume the task group can't go away on us if | 118 | * We can only assume the task group can't go away on us if |
123 | * autogroup_move_group() can see us on ->thread_group list. | 119 | * autogroup_move_group() can see us on ->thread_group list. |
diff --git a/kernel/sched/core.c b/kernel/sched/core.c index daaea922f482..03a67f09404c 100644 --- a/kernel/sched/core.c +++ b/kernel/sched/core.c | |||
@@ -7577,6 +7577,12 @@ static inline int tg_has_rt_tasks(struct task_group *tg) | |||
7577 | { | 7577 | { |
7578 | struct task_struct *g, *p; | 7578 | struct task_struct *g, *p; |
7579 | 7579 | ||
7580 | /* | ||
7581 | * Autogroups do not have RT tasks; see autogroup_create(). | ||
7582 | */ | ||
7583 | if (task_group_is_autogroup(tg)) | ||
7584 | return 0; | ||
7585 | |||
7580 | for_each_process_thread(g, p) { | 7586 | for_each_process_thread(g, p) { |
7581 | if (rt_task(p) && task_group(p) == tg) | 7587 | if (rt_task(p) && task_group(p) == tg) |
7582 | return 1; | 7588 | return 1; |