sched/fair: honor uclamp restrictions in fbt()

While calculating untilization of CPU during task placement in fbt(),
current code doesn't take uclamp into account which would lead to
selection of incorrect CPU for the task when uclamp restrictions
are in place for the task.

Change-Id: I8371affe3b37733d222e5c57953e53f91fc19a53
Signed-off-by: Satya Durga Srinivasu Prabhala <satyap@codeaurora.org>
This commit is contained in:
Satya Durga Srinivasu Prabhala 2020-04-17 09:23:40 -07:00
commit 22b04fa805

View file

@ -6616,7 +6616,7 @@ static void find_best_target(struct sched_domain *sd, cpumask_t *cpus,
* accounting. However, the blocked utilization may be zero.
*/
wake_util = cpu_util_without(i, p);
new_util = wake_util + task_util_est(p);
new_util = wake_util + uclamp_task_util(p);
spare_wake_cap = capacity_orig - wake_util;
if (spare_wake_cap > most_spare_wake_cap) {