Skip to content

Commit

Permalink
[PATCH] sched: remove on runqueue requeueing
Browse files Browse the repository at this point in the history
On runqueue time is used to elevate priority in schedule().

In the code it currently requeues tasks even if their priority is not
elevated, which would end up placing them at the end of their runqueue
array effectively delaying them instead of improving their priority.

Bug spotted by Mike Galbraith <efault@gmx.de>

This patch removes this requeueing.

Signed-off-by: Con Kolivas <kernel@kolivas.org>
Acked-by: Ingo Molnar <mingo@elte.hu>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Nick Piggin <nickpiggin@yahoo.com.au>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Con Kolivas authored and Linus Torvalds committed Mar 31, 2006
1 parent 5138930 commit 7c4bb1f
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions kernel/sched.c
Original file line number Diff line number Diff line change
Expand Up @@ -3023,8 +3023,7 @@ asmlinkage void __sched schedule(void)
dequeue_task(next, array);
next->prio = new_prio;
enqueue_task(next, array);
} else
requeue_task(next, array);
}
}
next->sleep_type = SLEEP_NORMAL;
switch_tasks:
Expand Down

0 comments on commit 7c4bb1f

Please sign in to comment.