diff options
author | Peter Zijlstra <a.p.zijlstra@chello.nl> | 2008-01-31 16:45:22 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-01-31 16:45:22 -0500 |
commit | ef9884e6f29bbe1075204f962a00f7533bf7e8f3 (patch) | |
tree | 6d67c6a7073ec99237336c32a8d6985d5b8a2f4e /kernel | |
parent | 296825cbe14d4c95ee9c41ca5824f7487bfb4d9d (diff) |
sched: let +nice tasks have smaller impact
Michel Dänzr has bisected an interactivity problem with
plus-reniced tasks back to this commit:
810e95ccd58d91369191aa4ecc9e6d4a10d8d0c8 is first bad commit
commit 810e95ccd58d91369191aa4ecc9e6d4a10d8d0c8
Author: Peter Zijlstra <a.p.zijlstra@chello.nl>
Date: Mon Oct 15 17:00:14 2007 +0200
sched: another wakeup_granularity fix
unit mis-match: wakeup_gran was used against a vruntime
fix this by assymetrically scaling the vtime of positive reniced
tasks.
Bisected-by: Michel Dänzer <michel@tungstengraphics.com>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/sched_fair.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c index cf958aefac33..6c091d6e159d 100644 --- a/kernel/sched_fair.c +++ b/kernel/sched_fair.c | |||
@@ -1106,7 +1106,11 @@ static void check_preempt_wakeup(struct rq *rq, struct task_struct *p) | |||
1106 | } | 1106 | } |
1107 | 1107 | ||
1108 | gran = sysctl_sched_wakeup_granularity; | 1108 | gran = sysctl_sched_wakeup_granularity; |
1109 | if (unlikely(se->load.weight != NICE_0_LOAD)) | 1109 | /* |
1110 | * More easily preempt - nice tasks, while not making | ||
1111 | * it harder for + nice tasks. | ||
1112 | */ | ||
1113 | if (unlikely(se->load.weight > NICE_0_LOAD)) | ||
1110 | gran = calc_delta_fair(gran, &se->load); | 1114 | gran = calc_delta_fair(gran, &se->load); |
1111 | 1115 | ||
1112 | if (pse->vruntime + gran < se->vruntime) | 1116 | if (pse->vruntime + gran < se->vruntime) |