Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e5689e1c authored by Saravana Kannan's avatar Saravana Kannan Committed by Rohit Gupta
Browse files

cpufreq: schedutil: Change to using WALT load



WALT load works better for UX workloads which are important for a
commercial mobile device.

Change-Id: I33fbb5c0566176288029e3249532f8c4b389add3
Signed-off-by: default avatarSaravana Kannan <skannan@codeaurora.org>
Signed-off-by: default avatarRohit Gupta <rohgup@codeaurora.org>
parent 73f29d2e
Loading
Loading
Loading
Loading
+5 −0
Original line number Original line Diff line number Diff line
@@ -59,6 +59,8 @@ struct sugov_cpu {
	unsigned int iowait_boost_max;
	unsigned int iowait_boost_max;
	u64 last_update;
	u64 last_update;


	struct sched_walt_cpu_load walt_load;

	/* The fields below are only needed when sharing a policy. */
	/* The fields below are only needed when sharing a policy. */
	unsigned long util;
	unsigned long util;
	unsigned long max;
	unsigned long max;
@@ -177,11 +179,14 @@ static void sugov_get_util(unsigned long *util, unsigned long *max, int cpu)
{
{
	struct rq *rq = cpu_rq(cpu);
	struct rq *rq = cpu_rq(cpu);
	unsigned long cfs_max;
	unsigned long cfs_max;
	struct sugov_cpu *loadcpu = &per_cpu(sugov_cpu, cpu);


	cfs_max = arch_scale_cpu_capacity(NULL, 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, cfs_max);
	*max = cfs_max;
	*max = cfs_max;

	*util = cpu_util_freq(cpu, &loadcpu->walt_load);
}
}


static void sugov_set_iowait_boost(struct sugov_cpu *sg_cpu, u64 time,
static void sugov_set_iowait_boost(struct sugov_cpu *sg_cpu, u64 time,