From: Eric Piel <Eric.Piel@tremplin-utc.net>
To: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>,
Jun Nakajima <jun.nakajima@intel.com>
Cc: cpufreq@lists.linux.org.uk
Subject: [PATCH] support for CPUFREQ_ETERNAL drivers by the ondemand governor
Date: Sun, 06 Feb 2005 23:33:49 +0100 [thread overview]
Message-ID: <42069B4D.6090505@tremplin-utc.net> (raw)
[-- Attachment #1: Type: text/plain, Size: 735 bytes --]
Hello,
For now the ondemand governor doesn't support the drivers which reports
a transition latency of CPUFREQ_ETERNAL. That's really a problem because
most of the drivers declare such a latency (simply because it's not
known, not really because the transition will take an eternal time).
All userspace daemons suport those drivers, they just don't pay
attention to the transition latency.
This patch proposes to consider a CPUFREQ_ETERNAL latency as the maximum
possible latency of the governor (10 ms). I think this should be
conservative enough to be safe with any driver.
Hoping you like it,
Eric
--
Support for CPUFREQ_ETERNAL drivers by the ondemand governor.
Signed-off-by: Eric Piel <eric.piel@tremplin-utc.net>
--
[-- Attachment #2: ondemand-accept-eternel-transition-latency-2.6.11-rc3.patch --]
[-- Type: text/x-patch, Size: 1345 bytes --]
--- linux-2.6.11-rc3/drivers/cpufreq/cpufreq_ondemand.c.orig 2005-02-05 17:09:30.000000000 +0100
+++ linux-2.6.11-rc3/drivers/cpufreq/cpufreq_ondemand.c 2005-02-05 18:02:55.000000000 +0100
@@ -56,7 +56,7 @@ static unsigned int def_sampling_rat
#define MAX_SAMPLING_RATE (500 * def_sampling_rate)
#define DEF_SAMPLING_RATE_LATENCY_MULTIPLIER (1000)
#define DEF_SAMPLING_DOWN_FACTOR (10)
-#define TRANSITION_LATENCY_LIMIT (10 * 1000)
+#define TRANSITION_LATENCY_LIMIT (10 * 1000 * 1000) /* ns */
#define sampling_rate_in_HZ(x) (((x * HZ) < (1000 * 1000))?1:((x * HZ) / (1000 * 1000)))
static void do_dbs_timer(void *data);
@@ -385,8 +385,8 @@ static int cpufreq_governor_dbs(struct c
(!policy->cur))
return -EINVAL;
- if (policy->cpuinfo.transition_latency >
- (TRANSITION_LATENCY_LIMIT * 1000))
+ if ((policy->cpuinfo.transition_latency > TRANSITION_LATENCY_LIMIT) &&
+ (policy->cpuinfo.transition_latency != CPUFREQ_ETERNAL))
return -EINVAL;
if (this_dbs_info->enable) /* Already enabled */
break;
@@ -416,6 +416,8 @@ static int cpufreq_governor_dbs(struct c
/* policy latency is in nS. Convert it to uS first */
latency = policy->cpuinfo.transition_latency;
+ if (latency == CPUFREQ_ETERNAL)
+ latency = TRANSITION_LATENCY_LIMIT;
if (latency < 1000)
latency = 1000;
[-- Attachment #3: Type: text/plain, Size: 147 bytes --]
_______________________________________________
Cpufreq mailing list
Cpufreq@lists.linux.org.uk
http://lists.linux.org.uk/mailman/listinfo/cpufreq
next reply other threads:[~2005-02-06 22:33 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-02-06 22:33 Eric Piel [this message]
2005-02-09 19:15 ` [PATCH] support for CPUFREQ_ETERNAL drivers by the ondemand governor Dominik Brodowski
2005-03-06 17:06 ` [PATCH] transition latency of speedstep-ich Eric Piel
[not found] ` <20050307182137.GB24559@isilmar.linta.de>
[not found] ` <432DD8DD.3090805@tremplin-utc.net>
[not found] ` <20050919101843.GA13041@isilmar.linta.de>
2005-09-19 22:35 ` [PATCH] transition latency of speedstep-ich (third try) Eric Piel
-- strict thread matches above, loose matches on Subject: below --
2005-02-07 18:29 [PATCH] support for CPUFREQ_ETERNAL drivers by the ondemand governor Pallipadi, Venkatesh
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=42069B4D.6090505@tremplin-utc.net \
--to=eric.piel@tremplin-utc.net \
--cc=cpufreq@lists.linux.org.uk \
--cc=jun.nakajima@intel.com \
--cc=venkatesh.pallipadi@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