* [2.6.0 cpufreq] longhaul trouble
@ 2003-12-19 16:32 Jurgen Kramer
2003-12-19 18:04 ` Dave Jones
0 siblings, 1 reply; 3+ messages in thread
From: Jurgen Kramer @ 2003-12-19 16:32 UTC (permalink / raw)
To: linux-kernel
When I insert the longhaul cpufreq module on my VIA EPIA 800 the system
completely freezes. It does not give any oops or other helpful error
message.
Through ACPI I can only use the throttling function, I can not switch
between 400 and 800 MHz.
Jurgen
output of /proc/cpu
processor : 0
vendor_id : CentaurHauls
cpu family : 6
model : 7
model name : VIA Ezra
stepping : 8
cpu MHz : 800.048
cache size : 64 KB
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 1
wp : yes
flags : fpu de tsc msr cx8 mtrr pge mmx 3dnow
bogomips : 1595.80
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [2.6.0 cpufreq] longhaul trouble
2003-12-19 16:32 [2.6.0 cpufreq] longhaul trouble Jurgen Kramer
@ 2003-12-19 18:04 ` Dave Jones
2003-12-20 10:13 ` Jurgen Kramer
0 siblings, 1 reply; 3+ messages in thread
From: Dave Jones @ 2003-12-19 18:04 UTC (permalink / raw)
To: Jurgen Kramer; +Cc: linux-kernel
On Fri, Dec 19, 2003 at 05:32:11PM +0100, Jurgen Kramer wrote:
> When I insert the longhaul cpufreq module on my VIA EPIA 800 the system
> completely freezes. It does not give any oops or other helpful error
> message.
>
Does this help ?
Dave
diff -urpN --exclude-from=/home/davej/.exclude bk-linus/arch/i386/kernel/cpu/cpufreq/longhaul.c cpufreq/arch/i386/kernel/cpu/cpufreq/longhaul.c
--- bk-linus/arch/i386/kernel/cpu/cpufreq/longhaul.c 2003-10-15 05:00:29.000000000 +0100
+++ cpufreq/arch/i386/kernel/cpu/cpufreq/longhaul.c 2003-11-21 02:20:59.000000000 +0000
@@ -170,6 +170,9 @@ static void longhaul_setstate (unsigned
* between that value multiplied by possible FSBs and cpu_mhz which
* was calculated at boot time. Really ugly, but no other way to do this.
*/
+
+#define ROUNDING 0xf
+
static int _guess (int guess, int maxmult)
{
int target;
@@ -177,16 +180,20 @@ static int _guess (int guess, int maxmul
target = ((maxmult/10)*guess);
if (maxmult%10 != 0)
target += (guess/2);
- target &= ~0xf;
+ target += ROUNDING/2;
+ target &= ~ROUNDING;
return target;
}
static int guess_fsb(int maxmult)
{
- int speed = (cpu_khz/1000) & ~0xf;
+ int speed = (cpu_khz/1000);
int i;
int speeds[3] = { 66, 100, 133 };
+ speed += ROUNDING/2;
+ speed &= ~ROUNDING;
+
for (i=0; i<3; i++) {
if (_guess(speeds[i],maxmult) == speed)
return speeds[i];
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [2.6.0 cpufreq] longhaul trouble
2003-12-19 18:04 ` Dave Jones
@ 2003-12-20 10:13 ` Jurgen Kramer
0 siblings, 0 replies; 3+ messages in thread
From: Jurgen Kramer @ 2003-12-20 10:13 UTC (permalink / raw)
To: Dave Jones; +Cc: linux-kernel
Yes it does!
from dmesg:
longhaul: VIA C3 'Ezra' [C5C] CPU detected. Longhaul v1 supported.
longhaul: MinMult=3.0x MaxMult=6.0x
longhaul: FSB: 133MHz Lowestspeed=399MHz Highestspeed=798MHz
from /sys/devices/system/cpu/cpu0/cpufreq:
::::::::::::::
cpuinfo_max_freq
::::::::::::::
798
::::::::::::::
cpuinfo_min_freq
::::::::::::::
399
::::::::::::::
scaling_available_governors
::::::::::::::
performance
::::::::::::::
scaling_driver
::::::::::::::
longhaul
::::::::::::::
scaling_governor
::::::::::::::
performance
::::::::::::::
scaling_max_freq
::::::::::::::
798
::::::::::::::
scaling_min_freq
::::::::::::::
399
Next step is to actually change the frequency. I am not really sure how
to do that with sysfs yet.
Cheers,
Jurgen
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2003-12-20 10:12 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-12-19 16:32 [2.6.0 cpufreq] longhaul trouble Jurgen Kramer
2003-12-19 18:04 ` Dave Jones
2003-12-20 10:13 ` Jurgen Kramer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox