Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 33550efb authored by Ionela Voinescu's avatar Ionela Voinescu Committed by Quentin Perret
Browse files

sched: add arch_scale_min_freq_capacity to track minimum capacity caps



If the minimum capacity of a group is capped by userspace or internal
dependencies which are not otherwise visible to the scheduler, we need
a way to see these and integrate this information into the energy
calculations and task placement decisions we make.

Add arch_scale_min_freq_capacity to determine the lowest capacity which
a specific cpu can provide under the current set of known constraints.

Change-Id: Ied4a1dc0982bbf42cb5ea2f27201d4363db59705
Signed-off-by: default avatarChris Redpath <chris.redpath@arm.com>
Signed-off-by: default avatarIonela Voinescu <ionela.voinescu@arm.com>
parent 0f96d867
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -1591,6 +1591,18 @@ unsigned long arch_scale_max_freq_capacity(struct sched_domain *sd, int cpu)
}
#endif

#ifndef arch_scale_min_freq_capacity
static __always_inline
unsigned long arch_scale_min_freq_capacity(struct sched_domain *sd, int cpu)
{
	/*
	 * Multiplied with any capacity value, this scale factor will return
	 * 0, which represents an un-capped state
	 */
	return 0;
}
#endif

#ifndef arch_scale_cpu_capacity
static __always_inline
unsigned long arch_scale_cpu_capacity(struct sched_domain *sd, int cpu)