Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1733572 > unrolled thread

[PATCH for 4.9 26/39] cpufreq: intel_pstate: Update pid_params.sample_rate_ns in pid_param_set()

Started by"Levin, Alexander (Sasha Levin)" <alexander.levin@verizon.com>
First post2017-09-18 02:50 +0200
Last post2017-09-18 02:50 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH for 4.9 26/39] cpufreq: intel_pstate: Update  pid_params.sample_rate_ns in pid_param_set() "Levin, Alexander (Sasha Levin)" <alexander.levin@verizon.com> - 2017-09-18 02:50 +0200

#1733572 — [PATCH for 4.9 26/39] cpufreq: intel_pstate: Update pid_params.sample_rate_ns in pid_param_set()

From"Levin, Alexander (Sasha Levin)" <alexander.levin@verizon.com>
Date2017-09-18 02:50 +0200
Subject[PATCH for 4.9 26/39] cpufreq: intel_pstate: Update pid_params.sample_rate_ns in pid_param_set()
Message-ID<uqSq5-72l-1@gated-at.bofh.it>
From: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>

[ Upstream commit 6e7408acd04d06c04981c0c0fb5a2462b16fae4f ]

Fix the debugfs interface for PID tuning to actually update
pid_params.sample_rate_ns on PID parameters updates, as changing
pid_params.sample_rate_ms via debugfs has no effect now.

Fixes: a4675fbc4a7a (cpufreq: intel_pstate: Replace timers with utilization update callbacks)
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
---
 drivers/cpufreq/intel_pstate.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/intel_pstate.c b/drivers/cpufreq/intel_pstate.c
index 80fa656da5ab..a59ae8e24d3d 100644
--- a/drivers/cpufreq/intel_pstate.c
+++ b/drivers/cpufreq/intel_pstate.c
@@ -609,6 +609,7 @@ static void intel_pstate_hwp_set_online_cpus(void)
 static int pid_param_set(void *data, u64 val)
 {
 	*(u32 *)data = val;
+	pid_params.sample_rate_ns = pid_params.sample_rate_ms * NSEC_PER_MSEC;
 	intel_pstate_reset_all_pid();
 	return 0;
 }
-- 
2.11.0

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web