* 2.4.19-pre10-ac1: Hardcoded cpu_khz in powernow-k6.c
@ 2002-06-05 0:52 Adrian Bunk
2002-06-05 1:02 ` Dave Jones
0 siblings, 1 reply; 3+ messages in thread
From: Adrian Bunk @ 2002-06-05 0:52 UTC (permalink / raw)
To: Dave Jones; +Cc: linux-kernel
Hi Dave,
while reading through powernow-k6.c in 2.4.19-pre10-ac1 I found the
following that seems to be a bug:
static unsigned long cpu_khz=350000;
Not every K6-2/3 runs at 350 MHz...
cu
Adrian
--
You only think this is a free country. Like the US the UK spends a lot of
time explaining its a free country because its a police state.
Alan Cox
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: 2.4.19-pre10-ac1: Hardcoded cpu_khz in powernow-k6.c
2002-06-05 0:52 2.4.19-pre10-ac1: Hardcoded cpu_khz in powernow-k6.c Adrian Bunk
@ 2002-06-05 1:02 ` Dave Jones
2002-06-05 6:04 ` Adrian Bunk
0 siblings, 1 reply; 3+ messages in thread
From: Dave Jones @ 2002-06-05 1:02 UTC (permalink / raw)
To: Adrian Bunk; +Cc: linux-kernel, arjanv
On Wed, Jun 05, 2002 at 02:52:15AM +0200, Adrian Bunk wrote:
> Hi Dave,
>
> while reading through powernow-k6.c in 2.4.19-pre10-ac1 I found the
> following that seems to be a bug:
>
> static unsigned long cpu_khz=350000;
>
> Not every K6-2/3 runs at 350 MHz...
iirc, there aren't any MSRs[*] on the K6-2 where we can read
the current FSB. I think 350MHz was used as it was probably
the slowest K6-2 to be found at the time. You can override
it with boot time arguments.
Dave.
[*] The K6 style powernow was reverse engineered, as there were
no publically available documents explaining it. All we can
do is scale multipliers. No voltage scaling, no FSB decoding.
--
| Dave Jones. http://www.codemonkey.org.uk
| SuSE Labs
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: 2.4.19-pre10-ac1: Hardcoded cpu_khz in powernow-k6.c
2002-06-05 1:02 ` Dave Jones
@ 2002-06-05 6:04 ` Adrian Bunk
0 siblings, 0 replies; 3+ messages in thread
From: Adrian Bunk @ 2002-06-05 6:04 UTC (permalink / raw)
To: Dave Jones; +Cc: linux-kernel, arjanv
On Wed, 5 Jun 2002, Dave Jones wrote:
> > while reading through powernow-k6.c in 2.4.19-pre10-ac1 I found the
> > following that seems to be a bug:
> >
> > static unsigned long cpu_khz=350000;
> >
> > Not every K6-2/3 runs at 350 MHz...
>
> iirc, there aren't any MSRs[*] on the K6-2 where we can read
> the current FSB. I think 350MHz was used as it was probably
> the slowest K6-2 to be found at the time. You can override
> it with boot time arguments.
Really? From reading the code I have the impression that cpu_khz holds
more or less the information a "cat /proc/cpuinfo | grep MHz" gives for a
CPU at it's "normal" speed. The only place where cpu_khz is used is in
busfreq = cpu_khz / get_cpu_multiplier() / 1000;
and this gives IMHO a wrong result if the "normal" speed of your CPU is
different from 350 MHz.
> Dave.
cu
Adrian
BTW: 350MHz was never the slowest K6-2, there are K6-2 @ 300 MHz.
--
You only think this is a free country. Like the US the UK spends a lot of
time explaining its a free country because its a police state.
Alan Cox
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2002-06-05 6:04 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-06-05 0:52 2.4.19-pre10-ac1: Hardcoded cpu_khz in powernow-k6.c Adrian Bunk
2002-06-05 1:02 ` Dave Jones
2002-06-05 6:04 ` Adrian Bunk
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox