public inbox for linux-pm@vger.kernel.org
 help / color / mirror / Atom feed
From: Jason Baron <jbaron@akamai.com>
To: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Cc: "viresh.kumar@linaro.org" <viresh.kumar@linaro.org>,
	"cpufreq@vger.kernel.org" <cpufreq@vger.kernel.org>,
	"linux-pm@vger.kernel.org" <linux-pm@vger.kernel.org>,
	Dirk Brandewie <dirk.j.brandewie@intel.com>,
	"dirk.brandewie@gmail.com" <dirk.brandewie@gmail.com>
Subject: Re: [PATCH] cpufreq: Apply default governor for setpolicy drivers
Date: Wed, 18 Dec 2013 22:51:26 -0500	[thread overview]
Message-ID: <52B26D3E.2070600@akamai.com> (raw)
In-Reply-To: <2651749.Dr3egRT25J@vostro.rjw.lan>

On 12/18/2013 06:33 PM, Rafael J. Wysocki wrote:
> On Wednesday, December 18, 2013 04:35:04 PM Jason Baron wrote:
>> On 12/18/2013 04:38 PM, Rafael J. Wysocki wrote:
>>> On Wednesday, December 18, 2013 08:31:02 PM Jason Baron wrote:
>>>> When configuring a default governor (via CONFIG_CPU_FREQ_DEFAULT_*) with the
>>>> 'intel_pstate' driver, I found that the default is not honored. For example,
>>>> configure 'CONFIG_CPU_FREQ_GOV_PERFORMANCE', and then do:
>>> intel_pstate doesn't use any cpufreq governors, so all of this is pointless
>>> for that particular driver anyway.
>>>
>>> Thanks!
>>>
>> Ok, but if I look at 'intel_pstate', I see a 'set_policy' call that does different
>> things if the policy is 'performance' vs. 'powersave'. Same for the 'longrun'
>> driver. So yes, they don't use the 'governors', but changing the governors
>> at runtime does appear to change change how they behave.
> OK, so you want the initial policy to be set in accordance with the
> CONFIG_CPU_FREQ_DEFAULT_* setting.  That makes sense, although it is not
> immediately clear from the patch changelog.
>
> That said the change in the patch looks kind of overly complicated.
> What about adding something like this instead?

Agreed - this is better. Will you just pull the below patch, or should
I re-post with a better changelog?

Thanks,

-Jason

> +       if (cpufreq_driver->setpolicy) {
> +               unsigned int ret;
> +
> +       	/* Use the default policyt if it is valid. */
> +               if (!cpufreq_parse_governor(policy->governor->name, &ret, NULL))
> +                       new_policy.policy = ret;
> +       }
>
> Rafael
>


  reply	other threads:[~2013-12-19  3:51 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-18 20:31 [PATCH] cpufreq: Apply default governor for setpolicy drivers Jason Baron
2013-12-18 21:38 ` Rafael J. Wysocki
2013-12-18 21:35   ` Jason Baron
2013-12-18 23:33     ` Rafael J. Wysocki
2013-12-19  3:51       ` Jason Baron [this message]
2013-12-19 13:18         ` Rafael J. Wysocki
2013-12-19  5:27       ` Viresh Kumar
2013-12-19 13:16         ` 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=52B26D3E.2070600@akamai.com \
    --to=jbaron@akamai.com \
    --cc=cpufreq@vger.kernel.org \
    --cc=dirk.brandewie@gmail.com \
    --cc=dirk.j.brandewie@intel.com \
    --cc=linux-pm@vger.kernel.org \
    --cc=rjw@rjwysocki.net \
    --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