Skip to content
Commit 70ebf51b authored by Pierre Gondois's avatar Pierre Gondois Committed by Deepak Kumar Mishra
Browse files

sched/fair: Use irq scaling for all sched classes



Time spent in irq context is not attributed to a specific task.
Irq scaling allows to consider this and reduce task/rq utilization
accordingly, given that the CPU capacity is smaller than expected.

scale_rt_capacity() excludes RT and DL tasks from irq scaling.
Only the available capacity is scaled, but RT and DL tasks should
also be scaled.

commit 523e979d ("sched/core: Use PELT for scale_rt_capacity()")
uses (for the CPU util):
  IRQ util_avg + (max_cap - IRQ util_avg / max_cap ) * /Sum rq util_avg
Applying irq scaling allows to extract the irq util avg. So irq util
avg should also be subtracted from the available capacity.

Thermal pressure is not execution time but reduces the maximum
possible capacity of a CPU. So irq scaling should not be applied.

Thus, in this order:
 - subtract thermal pressure
 - apply irq scaling on the remaining capacity (RT + DL + CFS + free)
 - subtract irq

Signed-off-by: Pierre Gondois's avatarPierre Gondois <pierre.gondois@arm.com>
parent cc65add2
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