diff options
author | Yuyang Du <yuyang.du@intel.com> | 2015-12-17 07:34:27 +0800 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2016-01-06 11:06:29 +0100 |
commit | 0905f04eb21fc1c2e690bed5d0418a061d56c225 (patch) | |
tree | 453158d4e26692cbd1244bf14fdc7dd2ffd9ac96 /kernel/sched/sched.h | |
parent | 5a1078043f844074cbd53981432778a8d5dd56e9 (diff) | |
download | lwn-0905f04eb21fc1c2e690bed5d0418a061d56c225.tar.gz lwn-0905f04eb21fc1c2e690bed5d0418a061d56c225.zip |
sched/fair: Fix new task's load avg removed from source CPU in wake_up_new_task()
If a newly created task is selected to go to a different CPU in fork
balance when it wakes up the first time, its load averages should
not be removed from the source CPU since they are never added to
it before. The same is also applicable to a never used group entity.
Fix it in remove_entity_load_avg(): when entity's last_update_time
is 0, simply return. This should precisely identify the case in
question, because in other migrations, the last_update_time is set
to 0 after remove_entity_load_avg().
Reported-by: Steve Muckle <steve.muckle@linaro.org>
Signed-off-by: Yuyang Du <yuyang.du@intel.com>
[peterz: cfs_rq_last_update_time]
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Dietmar Eggemann <dietmar.eggemann@arm.com>
Cc: Juri Lelli <Juri.Lelli@arm.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Morten Rasmussen <morten.rasmussen@arm.com>
Cc: Patrick Bellasi <patrick.bellasi@arm.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Vincent Guittot <vincent.guittot@linaro.org>
Link: http://lkml.kernel.org/r/20151216233427.GJ28098@intel.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'kernel/sched/sched.h')
0 files changed, 0 insertions, 0 deletions