aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2007-11-09 22:39:39 +0100
committerIngo Molnar <mingo@elte.hu>2007-11-09 22:39:39 +0100
commit8bc6767acb3236e0345e99cf198168e60e7ae456 (patch)
treebe9119dfaf3751ca49536bd569a0fc617daabda3
parentsched: remove PREEMPT_RESTRICT (diff)
downloadlinux-dev-8bc6767acb3236e0345e99cf198168e60e7ae456.tar.xz
linux-dev-8bc6767acb3236e0345e99cf198168e60e7ae456.zip
sched: wakeup preemption fix
wakeup preemption fix: do not make it dependent on p->prio. Preemption purely depends on ->vruntime. This improves preemption in mixed-nice-level workloads. Signed-off-by: Ingo Molnar <mingo@elte.hu>
-rw-r--r--kernel/sched_fair.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c
index fbcb426029d0..a3badf52bba2 100644
--- a/kernel/sched_fair.c
+++ b/kernel/sched_fair.c
@@ -863,10 +863,8 @@ static void check_preempt_wakeup(struct rq *rq, struct task_struct *p)
if (unlikely(se->load.weight != NICE_0_LOAD))
gran = calc_delta_fair(gran, &se->load);
- if (delta > gran) {
- if (p->prio < curr->prio)
- resched_task(curr);
- }
+ if (delta > gran)
+ resched_task(curr);
}
}