sched/walt: Improve the scheduler

This change is for general scheduler improvement.

Change-Id: Id19f38a2b9a67b130876cb8df1e88c6a56aa6aad
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
This commit is contained in:
Pavankumar Kondeti 2020-12-10 10:22:02 +05:30
commit 862319bb85

View file

@ -6591,8 +6591,10 @@ static void walt_find_best_target(struct sched_domain *sd, cpumask_t *cpus,
most_spare_wake_cap = LONG_MIN;
}
if (fbt_env->strict_max)
target_max_spare_cap = LONG_MIN;
if (fbt_env->strict_max) {
stop_index = 0;
most_spare_wake_cap = LONG_MIN;
}
if (p->state == TASK_RUNNING)
most_spare_wake_cap = ULONG_MAX;
@ -6656,9 +6658,8 @@ static void walt_find_best_target(struct sched_domain *sd, cpumask_t *cpus,
most_spare_cap_cpu = i;
}
if ((per_task_boost(cpu_rq(i)->curr) ==
TASK_BOOST_STRICT_MAX) &&
!fbt_env->strict_max)
if (per_task_boost(cpu_rq(i)->curr) ==
TASK_BOOST_STRICT_MAX)
continue;
/*
* Cumulative demand may already be accounting for the
@ -6677,7 +6678,7 @@ static void walt_find_best_target(struct sched_domain *sd, cpumask_t *cpus,
* than the one required to boost the task.
*/
new_util = max(min_util, new_util);
if (!fbt_env->strict_max && new_util > capacity_orig)
if (new_util > capacity_orig)
continue;
/*