lkml.org 
[lkml]   [2018]   [Jan]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH RESEND v3 3/3] cpufreq/schedutil: add rt utilization tracking
Date
add both cfs and rt utilization when selecting an OPP as rt can preempt and
steal cfs's running time

Signed-off-by: Vincent Guittot <vincent.guittot@linaro.org>
---
kernel/sched/cpufreq_schedutil.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/sched/cpufreq_schedutil.c b/kernel/sched/cpufreq_schedutil.c
index 2f52ec0..d8ba31b 100644
--- a/kernel/sched/cpufreq_schedutil.c
+++ b/kernel/sched/cpufreq_schedutil.c
@@ -183,7 +183,7 @@ static void sugov_get_util(unsigned long *util, unsigned long *max, int cpu)

cfs_max = arch_scale_cpu_capacity(NULL, cpu);

- *util = min(rq->cfs.avg.util_avg, cfs_max);
+ *util = min(rq->cfs.avg.util_avg + rq->rt.avg.util_avg, cfs_max);
*max = cfs_max;
}

--
2.7.4
\
 
 \ /
  Last update: 2018-01-14 23:19    [W:3.223 / U:2.424 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site