mirror of
https://github.com/torvalds/linux.git
synced 2026-07-30 11:11:26 +02:00
sched/walt: Handle -ve cpu capacity
There are instances where rt and irq load exceeds thermally limited capacity and results in a very high cpu_capacity. Fix it by comparing it against 0. Change-Id: Ice6e71cd8b5e0635ec1d79c7338a964cef70271d Signed-off-by: Sai Harshini Nimmala <quic_snimmala@quicinc.com>
This commit is contained in:
parent
ec30ed6a75
commit
ff2d763574
|
|
@ -4110,7 +4110,7 @@ static void android_rvh_update_cpu_capacity(void *unused, int cpu, unsigned long
|
|||
if (old != rq->cpu_capacity_orig)
|
||||
trace_update_cpu_capacity(cpu, rt_pressure, *capacity);
|
||||
|
||||
*capacity = max(rq->cpu_capacity_orig - rt_pressure, 1UL);
|
||||
*capacity = max((int)(rq->cpu_capacity_orig - rt_pressure), 0);
|
||||
}
|
||||
|
||||
static void android_rvh_sched_cpu_starting(void *unused, int cpu)
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user