[PATCH] sched/deadline: remove dl_new checking condition from dl_task_timer()

From: yjay.kim
Date: Sun Apr 27 2014 - 22:57:57 EST


From: "yjay.kim" <yjay.kim@xxxxxxx>

yield_task_dl() sets dl.dl_new as 1 and dequeue current dl task.
After that it expects that next bandwidth timer callback `dl_task_timer()` will
replenish budget of dl task and enqueue it again.

But current dl_task_timer() does nothing in case dl.dl_new is 1.
So when dl task calls sched_yield(), it will never be scheduled again.

dl_task_timer() should works in case dl_new is 1.

Signed-off-by: yjay.kim <yjay.kim@xxxxxxx>
---
kernel/sched/deadline.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/sched/deadline.c b/kernel/sched/deadline.c
index 27ef409..6fb4004 100644
--- a/kernel/sched/deadline.c
+++ b/kernel/sched/deadline.c
@@ -522,7 +522,7 @@ static enum hrtimer_restart dl_task_timer(struct hrtimer *timer)
* different from SCHED_DEADLINE or changed its reservation
* parameters (through sched_setscheduler()).
*/
- if (!dl_task(p) || dl_se->dl_new)
+ if (!dl_task(p))
goto unlock;

sched_clock_tick();
--
1.7.9.5

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/