From: Viresh Kumar <viresh.kumar@linaro.org>
To: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Cc: Linux PM list <linux-pm@vger.kernel.org>,
Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] cpufreq: intel_pstate: Fix HWP on boot CPU after system resume
Date: Mon, 2 May 2016 07:42:12 +0530 [thread overview]
Message-ID: <20160502021212.GE2855@vireshk-i7> (raw)
In-Reply-To: <7068194.yg8ROcCISN@vostro.rjw.lan>
On 02-05-16, 02:27, Rafael J. Wysocki wrote:
> From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
>
> Commit 41cfd64cf49fc "Update frequencies of policy->cpus only from
> ->set_policy()" changed the way the intel_pstate driver's ->set_policy
> callback updates the HWP (hardware-managed P-states) settings.
> A side effect of it is that if those settings are modified on the
> boot CPU during system suspend and wakeup, they will never be
> restored during subsequent system resume.
>
> To address this problem, allow cpufreq drivers that don't provide
> ->target or ->target_index callbacks to use ->suspend and ->resume
> callbacks and add a ->resume callback to intel_pstate to restore
> the HWP settings on the CPUs that belong to the given policy.
>
> Fixes: 41cfd64cf49fc "Update frequencies of policy->cpus only from ->set_policy()"
> Tested-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> ---
>
> Note: We've tried to address that issue by adding syscore_ops to
> intel_pstate and restoring the boot CPU's HWP setting from a
> syscore resume, but that turns out to be too early (apparently,
> the processor is not ready for that at that point).
>
> ---
> drivers/cpufreq/cpufreq.c | 28 ++++++++++++++++------------
> drivers/cpufreq/intel_pstate.c | 12 ++++++++++--
> 2 files changed, 26 insertions(+), 14 deletions(-)
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
--
viresh
prev parent reply other threads:[~2016-05-02 2:12 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-05-02 0:27 [PATCH] cpufreq: intel_pstate: Fix HWP on boot CPU after system resume Rafael J. Wysocki
2016-05-02 2:12 ` Viresh Kumar [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160502021212.GE2855@vireshk-i7 \
--to=viresh.kumar@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=rjw@rjwysocki.net \
--cc=srinivas.pandruvada@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox