|
@@ -3321,15 +3321,14 @@ static inline void schedule_debug(struct task_struct *prev)
|
|
static inline struct task_struct *
|
|
static inline struct task_struct *
|
|
pick_next_task(struct rq *rq, struct task_struct *prev, struct rq_flags *rf)
|
|
pick_next_task(struct rq *rq, struct task_struct *prev, struct rq_flags *rf)
|
|
{
|
|
{
|
|
- const struct sched_class *class = &fair_sched_class;
|
|
|
|
|
|
+ const struct sched_class *class;
|
|
struct task_struct *p;
|
|
struct task_struct *p;
|
|
|
|
|
|
/*
|
|
/*
|
|
* Optimization: we know that if all tasks are in
|
|
* Optimization: we know that if all tasks are in
|
|
* the fair class we can call that function directly:
|
|
* the fair class we can call that function directly:
|
|
*/
|
|
*/
|
|
- if (likely(prev->sched_class == class &&
|
|
|
|
- rq->nr_running == rq->cfs.h_nr_running)) {
|
|
|
|
|
|
+ if (likely(rq->nr_running == rq->cfs.h_nr_running)) {
|
|
p = fair_sched_class.pick_next_task(rq, prev, rf);
|
|
p = fair_sched_class.pick_next_task(rq, prev, rf);
|
|
if (unlikely(p == RETRY_TASK))
|
|
if (unlikely(p == RETRY_TASK))
|
|
goto again;
|
|
goto again;
|