summaryrefslogtreecommitdiffstats
path: root/init
diff options
context:
space:
mode:
authorByungchul Park2015-08-20 13:21:59 +0200
committerIngo Molnar2015-09-13 09:52:48 +0200
commit6efdb105d392da3ad5cb4ef951aed373cd049813 (patch)
tree155d66c29070d92f9b5b941d035ad032daa6b432 /init
parentsched/fair: Have task_move_group_fair() also detach entity load from the old ... (diff)
downloadkernel-qcow2-linux-6efdb105d392da3ad5cb4ef951aed373cd049813.tar.gz
kernel-qcow2-linux-6efdb105d392da3ad5cb4ef951aed373cd049813.tar.xz
kernel-qcow2-linux-6efdb105d392da3ad5cb4ef951aed373cd049813.zip
sched/fair: Fix switched_to_fair()'s per entity load tracking
Where switched_from_fair() will remove the entity's load from the runqueue, switched_to_fair() does not currently add it back. This means that when a task leaves the fair class for a short duration; say because of PI; we loose its load contribution. This can ripple forward and disturb the load tracking because other operations (enqueue, dequeue) assume its factored in. Only once the runqueue empties will the load tracking recover. When we add it back in, age the per entity average to match up with the runqueue age. This has the obvious problem that if the task leaves the fair class for a significant time, the load will age to 0. Employ the normal migration rule for inter-runqueue moves in task_move_group_fair(). Again, there is the obvious problem of the task migrating while not in the fair class. The alternative solution would be to to omit the chunk in attach_entity_load_avg(), which would effectively reset the timestamp and use whatever avg there was. Signed-off-by: Byungchul Park <byungchul.park@lge.com> [ Rewrote the changelog and comments. ] Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: yuyang.du@intel.com Link: http://lkml.kernel.org/r/1440069720-27038-5-git-send-email-byungchul.park@lge.com Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'init')
0 files changed, 0 insertions, 0 deletions