sched: Consider pi boosting in setscheduler()
authorThomas Gleixner <tglx@linutronix.de>
Fri, 7 Feb 2014 19:58:42 +0000 (20:58 +0100)
committerIngo Molnar <mingo@kernel.org>
Sat, 22 Feb 2014 17:10:04 +0000 (18:10 +0100)
commitc365c292d05908c6ea6f32708f331e21033fe71d
treefcaf27f6d0296ef48203f940d1ed9d8c02c56860
parent81a44c5441d7f7d2c3dc9105f4d65ad0d5818617
sched: Consider pi boosting in setscheduler()

If a PI boosted task policy/priority is modified by a setscheduler()
call we unconditionally dequeue and requeue the task if it is on the
runqueue even if the new priority is lower than the current effective
boosted priority. This can result in undesired reordering of the
priority bucket list.

If the new priority is less or equal than the current effective we
just store the new parameters in the task struct and leave the
scheduler class and the runqueue untouched. This is handled when the
task deboosts itself. Only if the new priority is higher than the
effective boosted priority we apply the change immediately.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
[ Rebase ontop of v3.14-rc1. ]
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Cc: Dario Faggioli <raistlin@linux.it>
Signed-off-by: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/1391803122-4425-7-git-send-email-bigeasy@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
include/linux/sched/rt.h
kernel/locking/rtmutex.c
kernel/sched/core.c