All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Doug Smythies" <dsmythies@telus.net>
To: 'Andy Tang' <andy.tang@nxp.com>,
	'Viresh Kumar' <viresh.kumar@linaro.org>,
	'Stratos Karafotis' <stratosk@semaphore.gr>
Cc: "'Rafael J. Wysocki'" <rafael@kernel.org>,
	"'Rafael J. Wysocki'" <rjw@rjwysocki.net>,
	'Linux PM' <linux-pm@vger.kernel.org>
Subject: RE: Ask for help on governor
Date: Thu, 14 Dec 2017 17:30:49 -0800	[thread overview]
Message-ID: <001f01d37544$5889d410$099d7c30$@net> (raw)
In-Reply-To: PJTJeNt3QC2CsPJTOebNwi

On 2017.12.13 18:42 Andy Tang wrote:
> On 2017.12.14 09:21 Doug wrote: 
>> 
>> diff --git a/drivers/cpufreq/cpufreq_governor.c
>> b/drivers/cpufreq/cpufreq_governor.c
>> index 58d4f4e..3493ca7 100644
>> --- a/drivers/cpufreq/cpufreq_governor.c
>> +++ b/drivers/cpufreq/cpufreq_governor.c
>> @@ -222,6 +222,7 @@ unsigned int dbs_update(struct cpufreq_policy
>> *policy)
>>                         max_load = load;
>>         }
>> 
>> +       idle_periods = 0;
>
> With this line added, conservative governor works well.
>
> Ondemand governor still can't work well.

Your original message said:

On 12-12-17, 02:46, Andy Tang wrote:
> I run into a question that conservative governor can't work while ondemand governor works well.

So, for my part of it, I never looked at ondemand.

> As I mentioned in earlier email, load varies from different sampling_rate.

Because that e-mail was html, a lot of people didn't get it, and it also is not
in the archives. Anyway:

On 2017.12.12 23:24 Andy wrote:

> I also found sampling_rate affects the CPU load dramatically.
>			sample rate
>			100000	10000	1000
> actual cpu load	1%		1%	1%
> cpu report load	1%		20%	40-100%
>
> So we can know that when sample_rate is higher than 10000us, cpufreq can not calculate the load correctly.

Can you tell us more details about how you did this test and how you know your data is correct?
In particular, what is your work/sleep frequency for your 1% load.
In my experience the work/sleep frequency has always been a very important consideration with these tests.
What is the tick rate of your kernel? Myself, I wouldn't expect a 1000 uSec sample period to work properly.

I used turbostat to verify my tests, and yes, on demand does start to misbehave if the sampling period
is short relative to the tick period (jiffy time), otherwise it was fine.

... Doug

  parent reply	other threads:[~2017-12-15  1:30 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <HE1PR0402MB282866171A847AE244A9F76CF3340@HE1PR0402MB2828.eurprd04.prod.outlook.com>
2017-12-12  7:30 ` Ask for help on governor Viresh Kumar
2017-12-12 16:18 ` Doug Smythies
2017-12-12 16:51   ` Rafael J. Wysocki
2017-12-13  3:10   ` Doug Smythies
2017-12-13  6:17     ` Viresh Kumar
2017-12-13  6:22       ` Andy Tang
2017-12-13  6:55         ` Viresh Kumar
2017-12-13 16:13       ` Doug Smythies
2017-12-14  1:21       ` Doug Smythies
2017-12-14  2:42         ` Andy Tang
2017-12-14 18:25           ` Stratos Karafotis
2017-12-15  1:29           ` Doug Smythies
2017-12-15  1:30         ` Doug Smythies [this message]
2017-12-15  1:56           ` Andy Tang
2017-12-15  7:37           ` Doug Smythies
2017-12-15  9:00             ` Andy Tang
2017-12-15 14:26               ` Rafael J. Wysocki
2017-12-15 15:53             ` Rafael J. Wysocki
2017-12-15 18:27             ` Doug Smythies
2017-12-15 23:53               ` Rafael J. Wysocki
2017-12-18  1:15               ` [PATCH] cpufreq: governor: Ensure sufficiently large sampling intervals Rafael J. Wysocki
2017-12-18  2:59                 ` Andy Tang
2017-12-18  4:38                 ` Viresh Kumar
2017-12-18 16:11               ` Doug Smythies
2017-12-18 17:42                 ` Rafael J. Wysocki
2017-12-13 16:13     ` Ask for help on governor Doug Smythies
2017-12-13 16:49     ` Doug Smythies

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='001f01d37544$5889d410$099d7c30$@net' \
    --to=dsmythies@telus.net \
    --cc=andy.tang@nxp.com \
    --cc=linux-pm@vger.kernel.org \
    --cc=rafael@kernel.org \
    --cc=rjw@rjwysocki.net \
    --cc=stratosk@semaphore.gr \
    --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.