mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Stephane Gasparini <stephane.gasparini@linux.intel.com>
To: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>,
	"Rafael J. Wysocki" <rjw@rjwysocki.net>,
	Josh Boyer <jwboyer@fedoraproject.org>,
	Philippe Longepe <philippe.longepe@linux.intel.com>,
	Len Brown <lenb@kernel.org>,
	Viresh Kumar <viresh.kumar@linaro.org>,
	Linux PM list <linux-pm@vger.kernel.org>,
	"Linux-Kernel@Vger. Kernel. Org" <linux-kernel@vger.kernel.org>
Subject: Re: intel_pstate oopses and lockdep report with Linux v4.5-1822-g63e30271b04c
Date: Mon, 21 Mar 2016 10:31:37 +0100	[thread overview]
Message-ID: <CA730279-06B8-411F-8E7B-B7A2CCF100F0@linux.intel.com> (raw)
In-Reply-To: <CAJZ5v0ijyXsrK7512oV0cM=jj9P+fXkq36RRc-iTDaAsSq7ugg@mail.gmail.com>


—
Steph




> On Mar 18, 2016, at 10:44 PM, Rafael J. Wysocki <rafael@kernel.org> wrote:
> 
> On Fri, Mar 18, 2016 at 7:32 PM, Stephane Gasparini
> <stephane.gasparini@linux.intel.com> wrote:
>> 
>> —
>> Steph
>> 
>> 
>> 
>> 
>>> On Mar 18, 2016, at 6:52 PM, Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> wrote:
>>> 
>>> On Fri, 2016-03-18 at 17:13 +0100, Stephane Gasparini wrote:
>>>> Rafael,
>>>> 
>>>> Why in step 3) both atom_set_pstate() and atom_set_pstate() were not
>>>> both
>>>> changed to use wrmsrl ?
>>> Initial Atom support was experimental as there were no users, till
>>> Chrome started using. So it was just a miss.
>>> 
>>> We should never have to use wrmsrl_on_cpu. But looks like
>>> cpufreq_driver.init() can't guarantee that.
>>> 
>>>> BTW, what is the interest of setting the pstate to LFM during
>>>> initialization ?
>>>> The BIOS is setting the pstate to either LFM, HFM or BFM, and why
>>>> bothering
>>>> changing it.
>>> This is a different issue. BIOS has different configuration option to
>>> enable fast boot modes which are not necessarily optimized for Linux.
>>> Some aggressive setting will force system to reboot on boot. So I will
>>> leave the way it is.
>>> 
>>> Thanks,
>>> Srinivas
>>> 
>> 
>> Still it does not answer my question, why when implementing a4675fbc4a7a
>> we did changed core for wrmsrl and not atom ?
> 
> By mistake?
> 
>> My point is that the issue was more due to a miss in the patch a4675fbc4a7a
>> rather than a difference of behavior between atom and core.
> 
> The issue is due to the fact that wrmsrl_on_cpu() is used in atom_set_pstate().
> 
> Moreover, core_set_pstate() doesn't use wrmsrl_on_cpu(), so in fact it
> is different from atom_set_pstate() in that respect.
> 
> Now, why and when that difference was introduced doesn't really
> matter.  What matters is whether or not it makes sense and what to do
> about it.
> 
> To me, it doesn't make sense.  wrmsrl() should be used on both Core
> and Atom to update the MSR in intel_pstate_adjust_busy_pstate().  In
> turn, wrmsrl_on_cpu() should be used by both of them on init/exit.
> That's exactly what happens with my patch applied, with a twist that
> on init/exit the P-state is always set to the minimum, so it is not
> even necessary to pass the pstate argument between functions in that
> case.
> 
>> The commit message is a bit misleading around this.
>> The wrmrl_on_cpu() is needed on both core and atom during init.
> 
> Yes, it is, but how is that related to the changelog of this patch?

Telling what you are saying in this email in answer to me would make the thing 
more clear IMO. 
1) the error seen is a side effect of the previous change, so the issue 
   was not existing before
2) the explanation would be more clear that during the init/exit wmsrl_on_cpu()
   and other wise wmsrl is the one to be used.


> 
> Thanks,
> Rafael

  reply	other threads:[~2016-03-21  9:31 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-17 13:02 Josh Boyer
2016-03-17 14:07 ` Rafael J. Wysocki
2016-03-17 14:34   ` Philippe Longepe
2016-03-17 16:44   ` Josh Boyer
2016-03-18  0:20     ` Rafael J. Wysocki
2016-03-18 12:37       ` Josh Boyer
2016-03-18 14:36         ` Rafael J. Wysocki
2016-03-18 16:13           ` Stephane Gasparini
2016-03-18 17:52             ` Srinivas Pandruvada
2016-03-18 18:32               ` Stephane Gasparini
2016-03-18 21:44                 ` Rafael J. Wysocki
2016-03-21  9:31                   ` Stephane Gasparini [this message]
2016-03-21 14:09                     ` Rafael J. Wysocki
2016-03-21  9:28               ` Stephane Gasparini
2016-03-21 14:11                 ` Rafael J. Wysocki
2016-03-21 18:58                   ` Srinivas Pandruvada
2016-03-21 22:02                     ` Rafael J. Wysocki
2016-03-18 17:35           ` Josh Boyer
2016-03-18 22:23             ` Rafael J. Wysocki

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=CA730279-06B8-411F-8E7B-B7A2CCF100F0@linux.intel.com \
    --to=stephane.gasparini@linux.intel.com \
    --cc=jwboyer@fedoraproject.org \
    --cc=lenb@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=philippe.longepe@linux.intel.com \
    --cc=rafael@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome