From: Wanpeng Li Date: Thu, 30 Oct 2014 22:39:34 +0000 (+0800) Subject: sched/deadline: Push task away if the deadline is equal to curr during wakeup X-Git-Url: http://git.efficios.com/?a=commitdiff_plain;h=6b0a563f3a534827c1b56e53c3fd0fccec3c7895;p=deliverable%2Flinux.git sched/deadline: Push task away if the deadline is equal to curr during wakeup This patch pushes task away if the dealine of the task is equal to current during wake up. The same behavior as rt class. Signed-off-by: Wanpeng Li Signed-off-by: Peter Zijlstra (Intel) Cc: Juri Lelli Cc: Kirill Tkhai Cc: Linus Torvalds Link: http://lkml.kernel.org/r/1414708776-124078-4-git-send-email-wanpeng.li@linux.intel.com Signed-off-by: Ingo Molnar --- diff --git a/kernel/sched/deadline.c b/kernel/sched/deadline.c index 8867a67b8f0a..e7779b3feec4 100644 --- a/kernel/sched/deadline.c +++ b/kernel/sched/deadline.c @@ -1506,7 +1506,7 @@ static void task_woken_dl(struct rq *rq, struct task_struct *p) p->nr_cpus_allowed > 1 && dl_task(rq->curr) && (rq->curr->nr_cpus_allowed < 2 || - dl_entity_preempt(&rq->curr->dl, &p->dl))) { + !dl_entity_preempt(&p->dl, &rq->curr->dl))) { push_dl_tasks(rq); } }