diff options
author | Thomas Gleixner <[email protected]> | 2015-05-05 19:49:49 +0200 |
---|---|---|
committer | Ingo Molnar <[email protected]> | 2015-05-08 11:53:55 +0200 |
commit | 0782e63bc6fe7e2d3408d250df11d388b7799c6b (patch) | |
tree | c8b370c5093a2c89bd9ed384971e189e09ec49b7 /fs/jbd/commit.c | |
parent | 3e0283a53f7d2f2dae7bc4aa7f3104cb5988018f (diff) |
sched: Handle priority boosted tasks proper in setscheduler()
Ronny reported that the following scenario is not handled correctly:
T1 (prio = 10)
lock(rtmutex);
T2 (prio = 20)
lock(rtmutex)
boost T1
T1 (prio = 20)
sys_set_scheduler(prio = 30)
T1 prio = 30
....
sys_set_scheduler(prio = 10)
T1 prio = 30
The last step is wrong as T1 should now be back at prio 20.
Commit c365c292d059 ("sched: Consider pi boosting in setscheduler()")
only handles the case where a boosted tasks tries to lower its
priority.
Fix it by taking the new effective priority into account for the
decision whether a change of the priority is required.
Reported-by: Ronny Meeus <[email protected]>
Tested-by: Steven Rostedt <[email protected]>
Signed-off-by: Thomas Gleixner <[email protected]>
Signed-off-by: Peter Zijlstra (Intel) <[email protected]>
Reviewed-by: Steven Rostedt <[email protected]>
Cc: <[email protected]>
Cc: Borislav Petkov <[email protected]>
Cc: H. Peter Anvin <[email protected]>
Cc: Mike Galbraith <[email protected]>
Fixes: c365c292d059 ("sched: Consider pi boosting in setscheduler()")
Link: http://lkml.kernel.org/r/alpine.DEB.2.11.1505051806060.4225@nanos
Signed-off-by: Ingo Molnar <[email protected]>
Diffstat (limited to 'fs/jbd/commit.c')
0 files changed, 0 insertions, 0 deletions