All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Doug Smythies" <dsmythies@telus.net>
To: "'Srinivas Pandruvada'" <srinivas.pandruvada@linux.intel.com>,
	<lenb@kernel.org>, <viresh.kumar@linaro.org>, <rjw@rjwysocki.net>
Cc: <linux-pm@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: RE: [PATCH] cpufreq: intel_pstate: Add additional OOB enabling bit
Date: Fri, 12 Jun 2020 07:11:00 -0700	[thread overview]
Message-ID: <000301d640c3$4e6d61c0$eb482540$@net> (raw)
In-Reply-To: <20200611174838.2822533-1-srinivas.pandruvada@linux.intel.com>

On 2020.06.11 10:49 Srinivas Pandruvada wrote:

> Add additional bit for OOB (Out of band) enabling of P-states. In this
> case intel_pstate shouldn't load. Currently, only "BIT(8) == 1" of the
> MSR MSR_MISC_PWR_MGMT is considered as OOB. Also add "BIT(18) == 1" as
> OOB condition.

Shouldn't those bits be defined in these files:
arch/x86/include/asm/msr-index.h
and
tools/arch/x86/include/asm/msr-index.h

?

By the way, I couldn't find those bits defined in Intel docs that I have.
 
> 
> Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
> ---
>  drivers/cpufreq/intel_pstate.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/cpufreq/intel_pstate.c b/drivers/cpufreq/intel_pstate.c
> index 8e23a698ce04..f21761443c90 100644
> --- a/drivers/cpufreq/intel_pstate.c
> +++ b/drivers/cpufreq/intel_pstate.c
> @@ -2686,8 +2686,8 @@ static bool __init intel_pstate_platform_pwr_mgmt_exists(void)
>  	id = x86_match_cpu(intel_pstate_cpu_oob_ids);
>  	if (id) {
>  		rdmsrl(MSR_MISC_PWR_MGMT, misc_pwr);
> -		if (misc_pwr & (1 << 8)) {
> -			pr_debug("Bit 8 in the MISC_PWR_MGMT MSR set\n");
> +		if ((misc_pwr & BIT(8)) || (misc_pwr & BIT(18))) {

And then those bit definitions used above.

> +			pr_debug("Bit 8 or 18 in the MISC_PWR_MGMT MSR set\n");

And then some insight also printed  with the debug message.
At least say "Out of Band".

>  			return true;
>  		}
>  	}
> --
> 2.24.1



  reply	other threads:[~2020-06-12 14:11 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-11 17:48 [PATCH] cpufreq: intel_pstate: Add additional OOB enabling bit Srinivas Pandruvada
2020-06-12 14:11 ` Doug Smythies [this message]
2020-06-12 15:45   ` Srinivas Pandruvada

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='000301d640c3$4e6d61c0$eb482540$@net' \
    --to=dsmythies@telus.net \
    --cc=lenb@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=rjw@rjwysocki.net \
    --cc=srinivas.pandruvada@linux.intel.com \
    --cc=viresh.kumar@linaro.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.