forked from luck/tmp_suning_uos_patched
sched/deadline: Fix rq->dl.pushable_tasks bug in push_dl_task()
Do not call dequeue_pushable_dl_task() when failing to push an eligible
task, as it remains pushable, merely not at this particular moment.
Actually the patch is the same behavior as commit 311e800e16
("sched,
rt: Fix rq->rt.pushable_tasks bug in push_rt_task()" in -rt side.
Signed-off-by: Wanpeng Li <wanpeng.li@linux.intel.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Juri Lelli <juri.lelli@arm.com>
Cc: Kirill Tkhai <ktkhai@parallels.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Link: http://lkml.kernel.org/r/1415258564-8573-1-git-send-email-wanpeng.li@linux.intel.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
This commit is contained in:
parent
cb0b9f2445
commit
c51b8ab5ad
|
@ -1328,6 +1328,7 @@ static int push_dl_task(struct rq *rq)
|
|||
{
|
||||
struct task_struct *next_task;
|
||||
struct rq *later_rq;
|
||||
int ret = 0;
|
||||
|
||||
if (!rq->dl.overloaded)
|
||||
return 0;
|
||||
|
@ -1373,7 +1374,6 @@ static int push_dl_task(struct rq *rq)
|
|||
* The task is still there. We don't try
|
||||
* again, some other cpu will pull it when ready.
|
||||
*/
|
||||
dequeue_pushable_dl_task(rq, next_task);
|
||||
goto out;
|
||||
}
|
||||
|
||||
|
@ -1389,6 +1389,7 @@ static int push_dl_task(struct rq *rq)
|
|||
deactivate_task(rq, next_task, 0);
|
||||
set_task_cpu(next_task, later_rq->cpu);
|
||||
activate_task(later_rq, next_task, 0);
|
||||
ret = 1;
|
||||
|
||||
resched_curr(later_rq);
|
||||
|
||||
|
@ -1397,7 +1398,7 @@ static int push_dl_task(struct rq *rq)
|
|||
out:
|
||||
put_task_struct(next_task);
|
||||
|
||||
return 1;
|
||||
return ret;
|
||||
}
|
||||
|
||||
static void push_dl_tasks(struct rq *rq)
|
||||
|
|
Loading…
Reference in New Issue
Block a user