Revert "sched/fair: Consider capacity inversion in util_fits_cpu()"

This reverts commit 98762616db.

It breaks the Android kernel abi, so revert it.  If it needs to come
back later, it can do so in an abi-safe way.

Bug: 161946584
Change-Id: Ia49398fa009014e2fb2d2133d99d46dbed02b528
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
Greg Kroah-Hartman
2023-06-20 17:21:04 +00:00
parent b7761c2622
commit 82536f79fd

View File

@@ -4173,16 +4173,12 @@ static inline int util_fits_cpu(unsigned long util,
* For uclamp_max, we can tolerate a drop in performance level as the
* goal is to cap the task. So it's okay if it's getting less.
*
* In case of capacity inversion we should honour the inverted capacity
* for both uclamp_min and uclamp_max all the time.
* In case of capacity inversion, which is not handled yet, we should
* honour the inverted capacity for both uclamp_min and uclamp_max all
* the time.
*/
capacity_orig = cpu_in_capacity_inversion(cpu);
if (capacity_orig) {
capacity_orig_thermal = capacity_orig;
} else {
capacity_orig = capacity_orig_of(cpu);
capacity_orig_thermal = capacity_orig - arch_scale_thermal_pressure(cpu);
}
capacity_orig = capacity_orig_of(cpu);
capacity_orig_thermal = capacity_orig - arch_scale_thermal_pressure(cpu);
/*
* We want to force a task to fit a cpu as implied by uclamp_max.