mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 1/2] cpufreq: Make iowait boost a policy option
@ 2017-05-18 18:30 Joel Fernandes
  2017-05-18 18:30 ` [PATCH 2/2] sched: Use iowait boost policy option in schedutil Joel Fernandes
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Joel Fernandes @ 2017-05-18 18:30 UTC (permalink / raw)
  To: linux-kernel; +Cc: rafael, Joel Fernandes

Make iowait boost a cpufreq policy option and enable it for intel_pstate
cpufreq driver. Governors like schedutil can use it to determine if
boosting for tasks that wake up with p->in_iowait set is needed.

Signed-off-by: Joel Fernandes <joelaf@google.com>
---
 drivers/cpufreq/intel_pstate.c | 1 +
 include/linux/cpufreq.h        | 3 +++
 2 files changed, 4 insertions(+)

diff --git a/drivers/cpufreq/intel_pstate.c b/drivers/cpufreq/intel_pstate.c
index b7de5bd76a31..a3099f099779 100644
--- a/drivers/cpufreq/intel_pstate.c
+++ b/drivers/cpufreq/intel_pstate.c
@@ -2239,6 +2239,7 @@ static int intel_cpufreq_cpu_init(struct cpufreq_policy *policy)
 
 	policy->cpuinfo.transition_latency = INTEL_CPUFREQ_TRANSITION_LATENCY;
 	policy->transition_delay_us = INTEL_CPUFREQ_TRANSITION_DELAY;
+	policy->iowait_boost_enable = 1;
 	/* This reflects the intel_pstate_get_cpu_pstates() setting. */
 	policy->cur = policy->cpuinfo.min_freq;
 
diff --git a/include/linux/cpufreq.h b/include/linux/cpufreq.h
index a5ce0bbeadb5..4bb086dbe7ec 100644
--- a/include/linux/cpufreq.h
+++ b/include/linux/cpufreq.h
@@ -127,6 +127,9 @@ struct cpufreq_policy {
 	 */
 	unsigned int		transition_delay_us;
 
+	/* Boost switch for tasks with p->in_iowait set */
+	unsigned int		iowait_boost_enable;
+
 	 /* Cached frequency lookup from cpufreq_driver_resolve_freq. */
 	unsigned int cached_target_freq;
 	int cached_resolved_idx;
-- 
2.13.0.303.g4ebf302169-goog

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2017-05-19  5:00 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-18 18:30 [PATCH 1/2] cpufreq: Make iowait boost a policy option Joel Fernandes
2017-05-18 18:30 ` [PATCH 2/2] sched: Use iowait boost policy option in schedutil Joel Fernandes
2017-05-19  1:08   ` Rafael J. Wysocki
2017-05-19  1:17     ` Joel Fernandes
2017-05-19  4:22       ` Rafael J. Wysocki
2017-05-19  4:39   ` Viresh Kumar
2017-05-19  4:56     ` Joel Fernandes
2017-05-19  4:59     ` Joel Fernandes
2017-05-19  1:03 ` [PATCH 1/2] cpufreq: Make iowait boost a policy option Rafael J. Wysocki
2017-05-19  1:24   ` Joel Fernandes
2017-05-19  4:17 ` Viresh Kumar
2017-05-19  5:00   ` Joel Fernandes

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome