Skip to content
Commit 518f475e authored by Quentin Perret's avatar Quentin Perret Committed by Dietmar Eggemann
Browse files

sched/fair: Fix util_avg of new tasks for asymmetric systems



When a new task wakes-up for the first time, its initial utilization
is set to half of the spare capacity of its CPU. The current
implementation of post_init_entity_util_avg() uses SCHED_CAPACITY_SCALE
directly as a capacity reference. As a result, on a big.LITTLE system, a
new task waking up on an idle little CPU will be given ~512 of util_avg,
even if the CPU's capacity is significantly less than that.

Fix this by computing the spare capacity with arch_scale_cpu_capacity().

Cc: Ingo Molnar <mingo@redhat.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Acked-by: Vincent Guittot's avatarVincent Guittot <vincent.guittot@linaro.org>
Signed-off-by: default avatarQuentin Perret <quentin.perret@arm.com>
parent 9fb2c0e8
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment