# Howto: Dynamic CPU speed with Athlon XP and nForce2 boards

## Hasw

Dynamic CPU speed with Athlon XP and nForce2 boards

Do you own a nForce2 based mainboards? Than that is maybe for you

if you want to dynamically change you CPU speed and voltage (power

saving when idle).

Frequency changing is available on all nForce2-based mainboards with

all CPUs which run on that board. However for dynamic CPU core voltage

changing there must a ATXP1 chip on the board.

On this boards VCore changing is supported (more are possible):

Abit NF7

Aopen AK79D-400VN

Chaintech CT-7NJ(S,L1)

DFI Infinity NFII Ultra

DFI Lanparty NFII Ultra

Epox 8RDA+

Epox 8(R,G)DA(3,6,+,I,E)

Shuttle AN35N Ultra V1.1

Shuttle SN45G (not V3)

Soltek 75FRN2-L

Soltek NV400-L64

Frequency changing is done via FSB control. This works good because the PCI/AGP-clock is controlled independently. RAM/FSB are synchronized. Mostly the RAM is the limiting factor.

Some maybe think why not change the FID (multiplier) like the Athlon Mobile (there are L-bridge mods to change a XP to a Mobile [1]). With some chipsets this is possible and there

 are patches for powernow-k7 to work on desktop boards. Unfortunately I've not heard yet that this works with the nForce2 chipset.

So now lets begin:

1. Get the cpufreq/atxp1 module working :

        Kernel 2.6.10 includes cpufreq-nforce2, but you can also

        get it from http://www.hasw.net/linux

	Kernel patches are available here: http://www.hasw.net/linux/atxp1-0.6.tar.bz2

        Now in the kernel-config: 

```

        

        Power management options (ACPI, APM)  --->

         CPU Frequency scaling  --->

                [*] CPU Frequency scaling

                Default CPUFreq governor (userspace)

                <M> nVidia nForce2 FSB changing       (only 2.6.10)

        

        Device Drivers  --->

         I2C support  --->

          <*> I2C support

          <M>   I2C device interface

          I2C Hardware Bus support  --->

           <M> ISA Bus support            (for hardware-monitoring chips)

           <M> Nvidia Nforce2

          Hardware Sensors Chip support  --->

           <M> ITE IT87xx and compatibles

           <M> Winbond W83781D, W83782D, W83783S, W83627HF, Asus AS99127F

           <M> Winbond W83627HF, W83627THF, W83637HF, W83697HF       (depending which chip your board uses)

          Other I2C Chip support  --->

              <M> Attansic ATXP1 VID controller

        
```

2. Test the cpufreq module:

```

        root@hasw root # modprobe cpufreq-nforce2

        root@hasw root # dmesg

        ......

        cpufreq: Detected nForce2 chipset revision A2

        cpufreq: FSB changing is maybe unstable and can lead to crashes and data loss.

        cpufreq: FSB currently at 200 MHz, FID 9.0

        
```

        If the detected FSB isn't correct, stop here and contact me (hasw@hasw.net).

        The FID can be set with:

```

        root@hasw cpufreq # modprobe cpufreq-nforce2 fid=95

        
```

        for a 9.5 multiplier.

        Otherwise you have now the cpufreq control-files in /sys:

```

        root@hasw root # cd /sys/devices/system/cpu/cpu0/cpufreq/

        root@hasw cpufreq # cat scaling_max_freq

        1800000

        root@hasw cpufreq # cat scaling_min_freq 

        1278000

        
```

        The frequency is in kHz. If you have compiled in multiple cpufreq governors, you have to switch it

	first, before you can do changes via userspace:

```

   echo userspace > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

   
```

	Now you can try to set a new frequency, for example:

```

        root@hasw cpufreq # echo 1700000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed

        root@hasw cpufreq # cat /proc/cpuinfo

        ....

        cpu MHz         : 1696.509

        ....

        
```

3. Find the minimum FSB (optional)

        Because of some internal chipset timings, the FSB is limited downwards. If no module

        option is given, the minimum FSB defaults to FSB at boot time - 50 MHz which should     

        work in the most cases.

If you want to set a lower FSB limit, use the min_fsb module option:

```

        root@hasw cpufreq # modprobe cpufreq-nforce2 min_fsb=140

        
```

        On the most boards, the limit is between 130 and 140 MHz. To be on the save side, use 140 instead of 133.

        For the Shuttle AN35N you can try to lower it < 100 MHz, they've the greatest working FSB range (some 60-240 MHz).

        Get prime95 from http://www.mersenne.org/freesoft.htm for stress testing. It works good for me because the torture test stops when the CPU produces calculation   errors. It detects

 errors even if it seems that all is working.

        Stop X and all uneeded services, so that there's no/small impact if the computer crashes (you have backups, of course  :Wink: 

        Now run the prime95 torture test and lower the CPU speed every 30s approx. 100 MHz:

```

        root@hasw cpufreq # echo 1700000 > scaling_setspeed

        root@hasw cpufreq # echo 1600000 > scaling_setspeed

        ...

        
```

        If prime95 reports hardware failure stop and add 50-100 MHz. Let prime95 run about one or two hours. If it crashes immediately, you also know where to stop  :Wink: 

        Now you have your minimum FSB and can add it as module-option:

```

        root@hasw root # echo "options cpufreq-nforce2 min_fsb=142" > /etc/modules.d/cpufreq-nforce2

        root@hasw root # modules-update

        
```

4. Get the atxp1 module working:

```

        root@hasw root # modprobe i2c_nforce2

        root@hasw root # modprobe atxp1

        root@hasw root # dmesg

        .... atxp1: Detected on SMBus nForce2 adapter at 5000, address 0x37

        ....

        
```

        To control the changes, also get hardware monitoring working:

```

        root@hasw root # modprobe i2c_isa

        root@hasw root # modprobe w83781d

        root@hasw root # cat /sys/bus/i2c/devices/2-0290/in1_input 

        1648

        
```

        This is for my 8RDA+ and shows 1648 mV CPU core voltage. You may have another monitoring chip and/or VCore input.

        Now first lower your CPU frequency and then the voltage:

```

        root@hasw root # echo 1400000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed

        root@hasw root # echo 1500 > /sys/bus/i2c/devices/0-0037/cpu_vid

        root@hasw root # dmesg

        ....

        atxp1: Setting VCore to 1500 mV (0x0e)

        root@hasw root # cat /sys/bus/i2c/devices/2-0290/in1_input 

        1520

        
```

        There's often a small positive offset, so that's normal if it shows a little bit more.

5. Find lowest core voltage for different frequencys 

You can use the same mechism used to find the minimum FSB. The smallest possible steps are 25mV. Decrease the voltage until it reports errors, add 50mV and you should be on the safe (stable) side.

6. Save changes 

        You now have the control over your CPU speed and core voltage. Happy power-saving  :Wink: 

        Add the modules to your /etc/modules.autoload.d/kernel-2.6 file to load the at startup, mine shows:

```

        ...

        cpufreq-nforce2

        i2c-nforce2

        i2c-isa

        atxp1

        w83781d

 
```

This does not work because the permissions are reset after some time.

---------------------------------------------------------------------

	Because the /sys files are only writeable by root, you may want to write them as user. If your user is the the group wheel you can add to your /etc/conf.d/local.start:

```

        # Change cpufreq permission

        CPUDIR="/sys/devices/system/cpu/cpu0/cpufreq"

        if [ -d $CPUDIR ]

        then

                echo userspace > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

      chgrp wheel $CPUDIR/scaling_setspeed

                chmod 664 $CPUDIR/scaling_setspeed

        fi

        # Change ATXP1 permission

        ATXP1="/sys/bus/i2c/devices/0-0037/cpu_vid"

        if [ -f $ATXP1 ]

        then

                chgrp wheel $ATXP1

                chmod 664 $ATXP1

        fi

        
```

---------------------------------------------------------------------

	Also important is that the most BIOSes only reset the voltages when the power was totally off (pull plug).

So you have to reset your VCore before reboot!

	You can put this in your /etc/conf.d/local.stop

```

   # Reset CPU core voltage

   ATXP1="/sys/bus/i2c/devices/0-0037/cpu_vid"

   if [ -f $ATXP1 ]

   then

      echo 1600 > $ATXP1

   fi

   
```

7. Some example scripts

        Here are some example scripts to set CPU speed and core voltage:

        set_cpuspeed.sh

```

        #!/bin/sh

        CPUDIR="/sys/devices/system/cpu/cpu0/cpufreq"

        VCORE="/sys/bus/i2c/devices/0-0037/cpu_vid"

        # Check if cpufreq driver and ATXP1 s available

        test -w $CPUDIR/scaling_setspeed || exit 0

        test -w $ATXP1 || exit 0

        if [ -z "$1" -o -z "$2" ]

        then

                echo "Usage: $0 (CPU speed in MHz) (Core voltage in mV)"

                exit 0

        fi

        CFREQ="`cat $CPUDIR/scaling_cur_freq`"

        CVCORE="`cat $VCORE`"

        NFREQ="$(($1*1000))"

        NVCORE="$2"

        if [ $NFREQ -gt $CFREQ ]

        then

                # First apply new Vcore

                echo $NVCORE > $VCORE

                # ...then new frequency

                echo $NFREQ > $CPUDIR/scaling_setspeed

        elif [ $NFREQ -lt $CFREQ ]

        then

                # First frequency

                echo $NFREQ > $CPUDIR/scaling_setspeed

                echo $NVCORE > $VCORE

        fi

        
```

        I'm using fluxbox and using a small script to generate a menu with CPU speed presets:

        cpuspeed:

```

        1800@1625

        1400@1450

        1278@1150

        
```

        create_cpumenu.sh:

```

        #!/bin/sh

        FBDIR="$HOME/.fluxbox"

        if [ ! -f $FBDIR/cpuspeed ]

        then

                exit 0

        fiecho "[submenu] (cpufreq) {CPU speed}" > $FBDIR/cpumenu

        

        for SPEED in `cat $FBDIR/cpuspeed`

        do

                FREQ="`echo  $SPEED | cut -d'@' -f1`"

                VCORE="`echo $SPEED | cut -d'@' -f2`"

        

                echo "[exec] ($FREQ MHz @ $VCORE mV) {$FBDIR/set_cpuspeed.sh $FREQ $VCORE}" >> $FBDIR/cpumenu

        done

        

        echo "[end]" >> $FBDIR/cpumenu

        
```

        Also my .torsmorc (system monitor) gets updated:

```

        ${color grey}Sensor:

        CPU:$color ${execi 15 ~/.sensor-cpu.sh}${color grey}

        
```

        sensor-cpu.sh:

```

        CPUDIR="/sys/devices/system/cpu/cpu0/cpufreq"

        SENSOR="/sys/bus/i2c/devices/2-0290"

        test -d $CPUDIR || exit 0

        test -d $SENSOR || exit 0

        FREQ="$((`cat $CPUDIR/scaling_cur_freq`/1000)) MHz"

        #FREQ="`awk '/MHz/ {print $4}' /proc/cpuinfo | sed -e 's/\..*$//'` MHz"

        VCORE="`cat $SENSOR/in1_input` mV"

        TEMP="$((`cat $SENSOR/temp2_input` / 1000)) <B0>C"

        echo -n "$FREQ @ $VCORE ($TEMP)"

        
```

        There are many other possibilities, including dynamic changing depending on the CPU load, etc.  :Wink: 

        Here is a nice Python-script which changes frequency and voltage on demand: http://www.lextech.net/work/autoFreq/Last edited by Hasw on Sun Mar 20, 2005 9:59 pm; edited 8 times in total

----------

## NewBlackDak

 *Hasw wrote:*   

> There are many other possibilities, including dynamic changing depending on the CPU load, etc. 

 

This would be nice for alot of people.  

Even though I have foldingathome or a compile running 24x7 I'm gonna try this to see if I Can get it working.

----------

## the_foxhond

How would I apply the cpufreq-nforce2 patch? I tried using make on it , but, it ended up returning an error, I'd c opy paste it if I had a middle mouse button but it seems to complain about a cpufreq not being declared.

----------

## Hasw

You have already running a 2.6 kernel version (>2.6.8, otherwise it won't work), so you should think switching to 2.6.10. If you don't want that, configure the kernel the same way mentioned above except without 

```
<M> nVidia nForce2 FSB changing
```

.

Install your new kernel and reboot.

Than get the module (it isn't the kernel-patch, my mistake) and just do:

```

hasw@hasw cpufreq-nforce2-0.2 $ make

make -C /lib/modules/2.6.10/build SUBDIRS=/home/hasw/cpufreq-nforce2-0.2 modules

make[1]: Entering directory `/usr/src/linux-2.6.10'

  CC [M]  /home/hasw/cpufreq-nforce2-0.2/cpufreq-nforce2.o

  Building modules, stage 2.

  MODPOST

  CC      /home/hasw/cpufreq-nforce2-0.2/cpufreq-nforce2.mod.o

  LD [M]  /home/hasw/cpufreq-nforce2-0.2/cpufreq-nforce2.ko

make[1]: Leaving directory `/usr/src/linux-2.6.10'

hasw@hasw cpufreq-nforce2-0.2 $

```

And copy the cpufreq-nforce2.ko module to /lib/modules/`uname-r`/kernel/arch/i386/kernel/cpu/cpufreq

If you got an error you should post it  :Wink:   Use a xterm or run gpm for c&p.

----------

## NewBlackDak

FYI if I try anything below 150(while booted above 166 FSB) FSB on my NF7-S if locks hard.  If I boot  with with 166 FSB I'm good from 133-166.

----------

## PrakashP

On my NF7-S 2.0 I have range 125 to 200 MHz. Using it since some months now.  :Smile: 

But I just tried the atxp1 module. Is it necessary to build this i2c stuff as modules? I have them compiled into kernel. Nevertheless trying to compile atxp1 I get:

```

make -C /lib/modules/2.6.10-ck1/build SUBDIRS=/home/light/atxp1-vcore-0.2 modules

make[1]: Entering directory `/usr/src/linux-2.6.10-ck1'

  Building modules, stage 2.

  MODPOST

*** Warning: "__fixunsdfsi" [/home/light/atxp1-vcore-0.2/atxp1.ko] undefined!

*** Warning: "__adddf3" [/home/light/atxp1-vcore-0.2/atxp1.ko] undefined!

*** Warning: "__floatsidf" [/home/light/atxp1-vcore-0.2/atxp1.ko] undefined!

make[1]: Leaving directory `/usr/src/linux-2.6.10-ck1'

cp ./atxp1.ko /lib/modules/`uname -r`/kernel/drivers/i2c/chips

cp: reguläre Datei ,,/lib/modules/2.6.10-ck1/kernel/drivers/i2c/chips" kann nicht angelegt werden: Datei oderVerzeichnis nicht gefunden

make: *** [default] Fehler 1

```

Ans ideas to fix? Is a kernel patch for this module available?

----------

## Hasw

To get no unresolved symbols, remove -msoft-float from the CFLAGS in arch/i386/Makefile. Not sure yet why this occurs, there are no FP operations in the module.

Then all should be fine, except the directory for I2C modules is missing because you have them in the kernel. Just run 

```
 mkdir -p /lib/modules/`uname -r`/kernel/drivers/i2c/chips 
```

 before make.

----------

## Hasw

The kernel patch is now available at: http://www.hasw.net/linux/atxp1-0.2.patch

----------

## PrakashP

Thanx for the patch!

Is is possible to fix the driver w/o messing with that makefile?

The trouble maker is:

```

static unsigned char atxp1_calc_vid(unsigned int vt) {

   return(((1850 - vt) / 25 + 0.5));

}

```

With your workaround it compiles. Haven't tested the module, though. Going to do that now.  :Smile: 

BTW, this is my suggestion for a fix:

```

static unsigned char atxp1_calc_vid(unsigned int vt) {

   return(((18500 - vt*10) / 25 + 5)/10);

}

```

(later) Yes! atxp1 works nicely.  :Smile:  Trying to find out how much I can undervolt at 1375MHz.  Nice work, Hasw!  :Cool: 

(even later) So I had a shock for a moment: While finding my lower bound I saw in dmesg that I cannot go below 1075V. Well I tried 1075, but ZAP my screen got black. HW reset didn't help as well. I had to "pull the plug" wait and then my machine got revived. What went wrong? 1100 works and I am finding out whether it is stable. 1,1V is the lowest setting in BIOS AFAIK, btw.

----------

## Hasw

Ok, thanks for the calculation fix.

Ups, yes the lower bound should be fixed. Because not all VCore controllers support 1.075V. You have a NF7 and the ID of 1.075V means here: power off CPU core voltage  :Wink: 

You need to fully power off, so that the device is reset.

----------

## PrakashP

Ah, OK, good explanation. So, users should be warned, I guess.  :Wink: 

----------

## Hasw

Updated the patch: http://www.hasw.net/linux/atxp1-0.3.tar.bz2

Fixed unresolved symbols problem

Added module option for lowest possible voltage (1075 or 1100 [default])

Fixed loop when setting 1850 mV

Added update lock

Renamed sys-device file from vcore to cpu_vid

----------

## PrakashP

Please fix this in your instructions above:

```

   if [ -f $ATXP1/vcore ] 

```

With atxp1 0.3 this obviously is wrong.  :Wink:  Then it wouldn't be bad if you add this line before all: 

```

echo userspace > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

```

BTW, is is possible to couple fsb and vcore in kernel space? I find it a bit dangerous currently (though nice that it works at all  :Smile:  ). It is easy to lock up the machine currently, as I found out while I was fighting with my permissions... Furthermore it is a bit risky if a user with wheel rights gets hacked...

----------

## Hasw

There are two problems coupling FSB and VCore in kernel-space:

1. The FSB:VCore pairs are different between various CPUs. 

2. The devices (kernel environment) is completely different.

"Problem" 1. can be solved by adding some /sys interface where the user can input these FSB, VCore combinations. But the second is a little bit more complicated I found.

The cpufreq-device is for the x86 arch and the ATXP1 is an I2C device which is platform independent. Also the kernel environments are different, writing a third module that controls both is possible, but not very nice.

Maybe adding two module options would help for the rights problem:

- Lower limit

- High limit, default: the one which was set at module loading

----------

## PrakashP

Reg problem 1: Of course, this is something each user has to find out on his/her own.  :Wink: 

Reg. problem 2: Couldn't you make some sort of "slave mode" to atxp1, that it only accepts changes in vcore from kernel space and a "master mode" for the the cpufrequ driver, that it controlls a slave which connects to it? Some sort of interface is needed, which apparently doesn't exist right now...

----------

## PrakashP

Ok, I am having a problem with my permissions. It seems they get reseted after some time. I guess this is udev coming in between. Perhaps the best would be to let udev handle the permissions? Does anyone have a nice ruleset for it? I could be on the wrong track, as well, as I don't know whether I can manipulate /sys with udev... Otherwise I'll help myself with sudo.

----------

## Hasw

Yes, I've already updated the howto. Haven't recognized it because when I experimenting with new modules I was logged in as root.

I don't think udev has something to do with it (I'm using devfsd), the sysfs is controlled by kernel and udev normally only controls /dev permissions. 

I haven't found out yet why the permissions are reset (I mean, why allow setting new permissions when they are reversed after some time?)

As you have mentioned a workaround could be running a script via sudo.

----------

## PrakashP

Too bad, on the second thought I also had supicions about udev... Well, I could bug lkml and hope to get an answer on what would be the correct way for this...I guess the kernel has no specifiv Docs about /sys?

But perhaps they would say to use an userspace prog, like speedfreq which has an daemon runninr with root rights and a client for the user...

[edit]

Thinking further I guess it is the best to modify eg speedfreq or whatever to set vcore as well. So you could couple fsb and vcore, but in userspace. Of course the coupling should only be modifyable by root, so this would be pretty safe then.Last edited by PrakashP on Wed Jan 05, 2005 10:07 am; edited 1 time in total

----------

## micmac

Hello!

I already tried cpufreq-nforce2 (without voltage changing) some time ago. Even with the default min_fsb it locked up my box eventually. The board is an ASUS A7N8X-X. I got an Athlon 1700+ and 2x256MB DDR. 

Is it even worth it? I mean the usual nforce2 board enables STPGNT per default (mine does, too). Can you measure the amound of electricity you save with additional cpufreq-nforce2?

Thanks!

mic

----------

## Sonic Lux

Thx it works on my NF7 from 100FSB@1,2Vcore till 225FSB@1,95Vcore.

Thx a lot for this howto !!

----------

## pussi

 *Hasw wrote:*   

> 
> 
>         Also my .torsmorc (system monitor) gets updated:
> 
> ```
> ...

 

I you're using torsmo 0.18 you can monitor your CPU frequency and temperature (already in 0.16?) without any scriping.

Add to your .torsmorc:

```
${color grey90}CPU Sensors:

    frequency: ${color white}${freq}MHz

    temperature: ${color white}${i2c temp <1 or 2 here :)>}°C
```

This should be faster than bash scripts but you can't monitor your vcore (unless you make another script for it).  :Wink: 

----------

## navier-stokes

If you also compile cpufreq governors in your kernel along with this patch, you can easily emerge cpudyn and configure it for your desktop (powersaving according to load). I'm using it now along with (emerge) gnome-cpufreq-applet-0.1.1 and it works great!

----------

## micmac

Yes, a daemon would be great to have. I mean with cpufreq-nforce2 you can easily use any daemon you want, like speedfreq etc. But what really would be ubercool is a daemon that not only can handle the FSB frequenzy changes but also the changes to cpu core voltage. But I think that's a hard task as no one can predict stable pairs of frequenzy and voltage. There are such tables for mobile CPUs like Pentium-M but not for all kinds of mainboards.

But of course we could set up the tables ourselves using programs like prime95, can't we. That way we get stable frequenzy (=multis?)/voltage pairs for our own hardware. Maybe these don't even on the cpu but on the mainboard only?

To sum it up, I'd hate doing all the switching manually. I'd rather have it done dynamically by a daemon. Can anyone suggest what to do?

micmac

----------

## Hasw

 *Quote:*   

> 
> 
> Is it even worth it? I mean the usual nforce2 board enables STPGNT per default (mine does, too). Can you measure the amound of electricity you save with additional cpufreq-nforce2? 
> 
> 

 

In addition with CPU core voltage changing: yes. STPGNT only comes in when the CPU is idle, while a low clocked CPU also saves power when not idle.

I've a 300W PSU and I hear it (fan) when I change the frequency/vcore in big steps. For 2000 @ 1.65V to 1000 @ 1.1V I think you save (under max. load) approx. 30-50W.

I think the best way is patching an existing cpufreq daemon to handle the FREQ<->VCore pairs or more general running commands before/after frequency changing. If there's someone who wants to do that, good. If not I'll do this when the ATXP1 module is finished (also the cpufreq-nforce2 gets a little bit tweaked).

----------

## Jinidog

I was able to reduce the FSB-clock on a Elitegroupe N2U400.

Although I didn't do much tests, I think you can add it to your list of supportet Mainboards.

----------

## Sonic Lux

Can i set for example "min_fsb=133" with non module version (hard into kernel) ?

How

thx

----------

## odborg

i see that the windows utility that you've developed supports vcore changes(testing) on asus a7n8x. Are you planing to support it on linux as well?

----------

## woZa

Nice work hasw...  :Cool: 

Been using 8rdavcore for ages on my windows install and the fsb module on linux. Good to see you got the vcore adjustments working too.

Just for the record my 8rda+ (rev 1.1) will go down to at least 110Mhz fsb (not tested lower as cpu will run 12.5*112@1.1v) and up to 199*12.5@1.75v (chipset voltage only 1.56v and not adjustable).

Going to give cpudyn a go to see if I can get some sort of cpu usage dependant raising and lowering...

----------

## Hasw

Jinidog: Does the CPU core voltage changing also work?

Passing driver options via the kernel command line should work like with other driver options (haven't tested this yet). Try adding min_fsb=133.

Support for the A7N8X series is on the way. I'm writing a module which supports the nVidia SMI bios interface (as used by their system utility). This allows monitoring temperatures and changing voltages.

----------

## micmac

Hello all,

I got hold of an AN35N mainboard and min_fsb=60 seems to work. Let's see if prime95 goes along with it  :Wink: 

But after loading i2c-nforce2 and atxp1 the cpu core voltage is 1,075V (I didn't change it yet):

cat /sys/bus/i2c/devices/2-0037/cpu_vid

1075

cat /sys/bus/i2c/devices/2-0037/name

atxp1

cat /proc/cpuinfo

processor       : 0

vendor_id       : AuthenticAMD

cpu family      : 6

model           : 8

model name      : AMD Athlon(tm) XP 1700+

stepping        : 1

cpu MHz         : 663.100

cache size      : 256 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 vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 mmx fxsr sse pni syscall mmxext 3dnowext 3dnow

bogomips        : 1308.25

Why is it 1,075V? It should be around 1,6V instead...

Changing it with "echo" doesn't seem to have any effect (it stays 1075).

mic

----------

## micmac

Torture Test ran 2 hours, 1 minutes - 0 errors, 0 warnings. So far so good.

But I think for atxp1 to work I need a real monitoring device which I seem not to be able to find. sensors-detect seems to fail. It suggests the it87 module but the ITE chip doesn't seem to deliver anything. Mmh, I gotta play around a bit  :Wink: 

Laters

mic

----------

## micmac

Hello Hasw!

The only sensor chip that seems to work is it87. I get this:

cat /sys/bus/i2c/devices/1-0290/in{0,1,2,3,4,5,6,7,8}_input

1600

1520

3248

3024

2928

912

1696

2976

4080

So it seems that /sys/bus/i2c/devices/1-0290/in0_input delivers th VCore which should be around 1,6V. Why doesn't the atxp1 modules recognize it as such? How can I tell it to use /sys/bus/i2c/devices/1-0290/in0_input?

Thanks!

mic

----------

## Hasw

The ATXP1 does not use any sensors to get the CPU core voltage (it does not measure it!).

There are two things possible:

1. Have you set the CPU core voltage in the BIOS to "Default" or "Automatic"? If yes, try set it manually to 1.6V.

2. There's no ATXP1 and the module "misdetected" no/another device (ATXP2,3,5). There will be an update in the next time to avoid this. It would be nice if you can check if a ATXP1 chip is on your board (mostly between/near CPU and DIMM sockets).

----------

## kostian

Thanks for the howto.

scaling fsb and cpudyn work fine here. can't change core volatge though. well its a cheap piece of crap biostar m7ncd after all   :Twisted Evil: 

P.S. if anyone finds out how to stop /sys permissions from resetting let me know   :Wink: 

----------

## micmac

 *Hasw wrote:*   

> The ATXP1 does not use any sensors to get the CPU core voltage (it does not measure it!).
> 
> There are two things possible:
> 
> 1. Have you set the CPU core voltage in the BIOS to "Default" or "Automatic"? If yes, try set it manually to 1.6V.
> ...

 

Hello Hasw!

Regarding 1.: It was set to auto. So that may have been the problem.

Regarding 2.:  I can take a look at the mainboard very easily because I already removed it from the box.  :Wink:  It has an ATXP1. My other mainboard, an A7N8X-X has an ATXP2 btw. 

I removed the board because there were some hassles:

* Even though prime95 ran 2 hours without any errors the box hangs eventually with cpufreq-nforce2. 

* The board doesn't operate fully without a graphic card (it's a TV box with a DVB card which has a TV out).

Laters

mic

Edit: I'll test atxp1 again when I get an answer from the Taiwan Shuttle Support. I will put the mainboard back in place if they figure out the graphic card problem.Last edited by micmac on Wed Jan 19, 2005 5:24 am; edited 1 time in total

----------

## Hasw

 *micmac wrote:*   

> 
> 
> Regarding 1.: It was set to auto. So that may have been the problem.
> 
> Regarding 2.:  I can take a look at the mainboard very easily because I already removed it from the box.  It has an ATXP1. My other mainboard, an A7N8X-X has an ATXP2 btw. 
> ...

 

So does it work now?

The ATXP2 is the same as the ATXP1 but without VID control (the Asus boards using another voltage control mechanism).

I know this "hang-after-a-while-problem". Add 5-10MHz FSB (lower limit) / 25-25mV CPU voltage (lower limit), this should help.

----------

## micmac

 *Hasw wrote:*   

>  *micmac wrote:*   
> 
> Regarding 1.: It was set to auto. So that may have been the problem.
> 
> Regarding 2.:  I can take a look at the mainboard very easily because I already removed it from the box.  It has an ATXP1. My other mainboard, an A7N8X-X has an ATXP2 btw. 
> ...

 

Hi Hasw!

Actually it works now. Loading the it87 and setting the VCore Voltage manually in the BIOS setup is necessary. The CPU fan often goes off  :Smile: 

Thanks!

mic

----------

## micmac

Hello all!

It now runs very well here. I set min_fsb to 70, my lowest frequency is around 770MHz. At this speed the voltage can be 1.1V. After a few minutes from normal settings to these my cooler block under the fan feels colder than room temperature. It's awesome.

What would be a proper approach to doing the changes dynamically by any kind of daemon? I think there wouldn't have to be thousands of different policies because all this happens on a desktop system. So if we need power we should get it and if not than everything could be dropped to minimum power.

Would changing an existing cpufreq daemon be  proper approach? Or would it be easier to write a rather small new one?

The speedfreq daemon checks /proc/uptime every now and then to see if a decrease/increase is necessary. Sounds charming to me. With cpufreq-nforce we don't get scaling_available_frequencies in /sys, so we would need our own table including voltages.

Best regards

micmac    :Very Happy: 

----------

## Jinidog

I'm not able to check wether the Elitegroup N2U400 supports changing the Vcore.

I'm not able to find the "Attansic ATXP1 VID controller " in my kernel-config.

Anyway, I've another problem.

When I try to increase the frequency above the FSB that is set in the BIOS, my system crashs.

Okay, I can avoid this  :Wink: 

But I tried speedfreqd and it's reducing the CPU-frequency correctly when idle, but when I run glxgears and speedfreqd tries to increase the CPU-frequency, my system crashs after a few seconds.

What can I do?

How can I tell speedfreqd, not to increase the frequency too much above the allowed speed?

----------

## CMDR_PAIN

 *kostian wrote:*   

> Thanks for the howto.
> 
> scaling fsb and cpudyn work fine here. can't change core volatge though. well its a cheap piece of crap biostar m7ncd after all  
> 
> P.S. if anyone finds out how to stop /sys permissions from resetting let me know  

 

I`ve just added a group "wentyle" (eng would be "fans") and wrote a line to my rc.local (Slackware has BSD style init):

chown -R root.wentyle /sys

chmod -R 770 /sys

----------

## Hasw

 *Jinidog wrote:*   

> 
> 
> I'm not able to find the "Attansic ATXP1 VID controller " in my kernel-config.
> 
> Anyway, I've another problem.
> ...

 

You have to apply a patch to get the atxp1 kernel module (http://www.hasw.net/linux/atxp1-0.3.tar.bz2).

How do you increase the FSB above the FSB set in BIOS? Max. FSB is set to FSB at boot time. It seems something is going wrong here...

Is dmesg showing the correct FSB at loading? Something like 

```

cpufreq: FSB currently at 200 MHz, FID 9.5

```

Which lower limit have you set and what's your max. FSB?

----------

## weingbz

I know it's an old thread but I have 2 questions which haven't been asked.

 *Hasw wrote:*   

> Dynamic CPU speed with Athlon XP and nForce2 boards
> 
> On this boards VCore changing is supported (more are possible):
> 
> Abit NF7
> ...

 

Do you have a list of possible ranges with different motherboards? I'm thinking of buying a EPoX EP-8RDA3I Pro. Is that supported or only the non-pro version? Do you know if this works on an ABIT AN-7?

I'm a bit confused on the one hand you write:

 *Hasw wrote:*   

> Frequency changing is done via FSB control. This works good because the PCI/AGP-clock is controlled independently. RAM/FSB are synchronized. Mostly the RAM is the limiting factor.
> 
> Some maybe think why not change the FID (multiplier) like the Athlon Mobile (there are L-bridge mods to change a XP to a Mobile [1]). With some chipsets this is possible and there
> 
>  are patches for powernow-k7 to work on desktop boards. Unfortunately I've not heard yet that this works with the nForce2 chipset.
> ...

 

And then a few paragraphs later you show how to change the FID:

 *Hasw wrote:*   

>         The FID can be set with:
> 
> ```
> 
>         root@hasw cpufreq # modprobe cpufreq-nforce2 fid=95
> ...

 

Which is it can you change the FID on the fly or not?

 Thanks for your help

----------

## Hasw

As far as I know it works on all 8RDA/8RGA boards. The voltage range is usually 1.1V-1.85V (I'm working on > 1.85V for some boards).

The Abit AN-7 is not supported because it uses the Abit uGuru microcontroller and they don't want to help me with information about programming this thing.

The module option does not set the FID. You can use it if your FID is wrongly detected (it's calculated at module startup by current freq/FSB). If you have lowered the FSB, unloaded the module and reload it, it detects the wrong FID.

----------

## weingbz

 *Hasw wrote:*   

> As far as I know it works on all 8RDA/8RGA boards. The voltage range is usually 1.1V-1.85V (I'm working on > 1.85V for some boards).
> 
> 

 

And can you set the FSB dynamically from 100-200Mhz? Because in the thread I read that on some boards you can only use the boot FSB as max FSB and can only go 50Mhz lower.

 *Hasw wrote:*   

> 
> 
> The Abit AN-7 is not supported because it uses the Abit uGuru microcontroller and they don't want to help me with information about programming this thing.
> 
> 

 

Well then they've lost one possible customer. Have you asked and they said no?

 *Hasw wrote:*   

> 
> 
> The module option does not set the FID. You can use it if your FID is wrongly detected (it's calculated at module startup by current freq/FSB). If you have lowered the FSB, unloaded the module and reload it, it detects the wrong FID.

 

Ah so it's only for correction of the detection. Do you know on  which boards/chipsets you can set the FID?

Thanks for your help

----------

## Hasw

The available FSB range depends on the used RAM modules/timings. Boot-FSB - 50 MHz should work on all boards, some can go lower (best results Shuttle AN35N 60-230).

Asked two times, told them why, but they've said clearly no.

It should work on the most Via, SiS and AMD chipsets for XP CPUs, see http://www.cpuheat.wz.cz/html/Tweaks.htm for a list.

----------

## weingbz

 *Hasw wrote:*   

> It should work on the most Via, SiS and AMD chipsets for XP CPUs, see http://www.cpuheat.wz.cz/html/Tweaks.htm for a list.

 

But only in windows   :Sad: 

----------

## Hasw

No, there are patches for the cpufreq powernow-k7 module to support mobile CPUs in desktop boards. Check the cpufreq mailing list for more (search for "[PATCH] Another powernow-k7 patch for Desktop XP-M usage").

----------

## micmac

Hello!

I ran the cpufreq/atxp1 setup for quite some time now, but sometimes the computer would just hang after increasing voltage/frequency, even if I did it incrementally. Another downside was that I had to boot with a rescue disc to fix my filesystems after these hangs.

Would this be avoidable with a real mobile CPU? Or would this method not even work with a CPU like this?

Thanks

micmac

----------

## phranzee

is it possible to change the multiplier?

----------

## Hasw

 *micmac wrote:*   

> Hello!
> 
> I ran the cpufreq/atxp1 setup for quite some time now, but sometimes the computer would just hang after increasing voltage/frequency, even if I did it incrementally. Another downside was that I had to boot with a rescue disc to fix my filesystems after these hangs.
> 
> Would this be avoidable with a real mobile CPU? Or would this method not even work with a CPU like this?
> ...

 

Try to decrease your FSB range and increase your lowest core voltage a little bit, what are your current used values? If you are testing the available FSB/core voltage range, you should stop all uneeded programs and services to avoid data loss. Or compile/load the modules using a LiveCD like Knoppix. These two modules doesn't difference between a mobile or a normal CPU, but a mobile CPU will mostly run with a lower voltage.

 *phranzee wrote:*   

> 
> 
> is it possible to change the multiplier?
> 
> 

 

I've not heard yet that it's possible on nForce2 boards, however for other chipset it works. Check my last message.

----------

## micmac

Hi Hasw!

I used min_fsb=60 and 1,1V (1100). In fact I only used this pair and the default (aka full speed). The problem is not running these speeds. prime95 didn't see any errors for 2 hours while running 60/1100. But changing between them often made the box hang. Afterwards my xfs filesystems needed to be repaired.

I'm not sure if I dare to take the risk again  :Smile: 

Greets

micmac

----------

## Hasw

You should use some steps between the changes 60@1100->Fullspeed and backwards. I think that's maybe a little bit too much  :Wink:  After all these functions are experimental and may not work on all systems perfect. If somebody isn't sure if it works, he should not try it on a important system without backup.

----------

## dob

What cpufreq daemon do you guys use?

I use powernowd which is fine and easy to set up; but I only change the FSB and not the voltage

----------

## energy

I just set up my box to use cpufreq scaling... Now my XP2200+ (1,8GHz) is running at 1,3GHz  :Smile: 

The FSB range that works for me is 95-133MHz (my cpu is 133MHz FSB model) I can go even

below 1,3GHz and it works perfectly, BUT it hangs immediately after I try to raise it up again...

So I can go way down but never get back up  :Laughing: 

Oh, the motherboard is Asus A7N8X.

EDIT: Did some tweaking, now running 12x150MHz. So now I can scale down to 1,14GHz without

any problems. Solid as a rock @ full speed and 1,14GHz  :Smile: 

----------

## KpR2000

I am using  2.6.11-nitro0 and the patch atxp-1.0.3 patch applied correctly. 

But I  have problems to compile the kernel: 

Following error occured at atxpl_detect function:

```

.

.

  CC [M]  drivers/i2c/chips/w83781d.o

  CC [M]  drivers/i2c/chips/atxp1.o

drivers/i2c/chips/atxp1.c: In Funktion »atxp1_detect«:

drivers/i2c/chips/atxp1.c:235: error: structure has no member named `id'

make[3]: *** [drivers/i2c/chips/atxp1.o] Fehler 1

make[2]: *** [drivers/i2c/chips] Fehler 2

make[1]: *** [drivers/i2c] Fehler 2

make: *** [drivers] Fehler 2

```

Could it be a simple fix to add or set a correct id? I have no idea.

Anyone a fix?

----------

## PrakashP

Yes, put /* */ around the offending line.

----------

## hothead

@Hasw

You wrote that VCore changing is supported on 

Leadtek K7NCR-18D. I've a K7NCR-18D Pro but when I load the 

atxp1 module I do not get any kernel message. I looked at the board and 

I cannot find a chip named atxp1. How do you switch the VCore here?

Regards 

Ruben

----------

## chx1975

Motherboard is 8RDA+, CPU is a Mobile Barton 2500+.

Sensors says I have "Vcore 1" which is 1.7V and "Vcore 2" which is 1.25 -- I have echo 1250 >/sys/bus/i2c/devices/0-0037/cpu_vid so 1.25 is fine, it's great. But what's that alarmingly high 1.7V?

Anyone has a working sensors file for this MB?

----------

## woZa

 *chx1975 wrote:*   

> Motherboard is 8RDA+, CPU is a Mobile Barton 2500+.
> 
> Sensors says I have "Vcore 1" which is 1.7V and "Vcore 2" which is 1.25 -- I have echo 1250 >/sys/bus/i2c/devices/0-0037/cpu_vid so 1.25 is fine, it's great. But what's that alarmingly high 1.7V?
> 
> Anyone has a working sensors file for this MB?

 

Probably your chipset voltage (vdd) mine is only 1.56v but isn't adjustable - later models were I believe.

1.7 isn't so high. Some people run it at 2.0v (that is quite high). Just check the temp for the chipset and so long as it doesn't get above around 45c you should be fine.

----------

## chx1975

 *woZa wrote:*   

>  *chx1975 wrote:*   Motherboard is 8RDA+, CPU is a Mobile Barton 2500+.
> 
> Sensors says I have "Vcore 1" which is 1.7V and "Vcore 2" which is 1.25 -- I have echo 1250 >/sys/bus/i2c/devices/0-0037/cpu_vid so 1.25 is fine, it's great. But what's that alarmingly high 1.7V?
> 
> Anyone has a working sensors file for this MB? 
> ...

 

Oh, it's VDD? That's adjustable, thanks, a hardware hacker friend of mine have soldered something and there is a nice knob to tune it up and down  :Smile:  I guess yours' is 1.65V.

What about a working sensors file?

----------

## woZa

 *Quote:*   

>  I guess yours' is 1.65V. 

 

I wish it was but it's only 1.56v and my last attempt at soldering something small and fiddley didn't really work out too well so I am not about to trash my board by trying to solder a resistor onto it! Still runs stable at 200Mhz fsb though.

----------

## dob

Can the 'ondemand' cpufreq governor be used with an nforce2 board?

The ondemand governor looks interesting because it will automatically adjust the cpu speed based on cpu usage, without having to use a userspace daemon like cpufreqd / speedfreqd etc.

In theory, this is how you proceed:

1) Check that the on demand governor is available (it is!)

```
# cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors

ondemand powersave userspace performance 
```

2) Use the ondemand governor as default

```
#  echo ondemand  > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
```

However, it doesn't work ... scaling_governor remains at the previous value. I can switch between powersave / userspace etc fine, but it won't let me use ondemand  :Shocked: 

----------

## hothead

Is nobody there who knows how to change the VCore on a Leadtek K7NCR18D?

----------

## mikeraach

I have a NF7-S v2 and all modules compiled/installed.

I have my rig overclocked to 10x230, so I set my min fsb to 180.  Prime95 fails after a few minutes and I often get programs crashing.

I reboot, then try min fsb to 200 and get same results as above...min 220, same.

This is with a completely stable 230fsb setup (prime95 too).

I tried flashing to a different bios, no change, and I tried setting my chip to default 11x166 (xp2500).  Setting min fsb to anything resulted in a instability problem as well.

Thinking this was maybe a problem with the way linux handles changing fsb with my board, I tried 8rdavcore and have the same problems as listed above.

HOWEVER, I have used 8rdavcore to RAISE the fsb and had no problems.  It seems like my board just doesn't like lowering the fsb from stock.  Is there a way that I can overclock instead of underclock with the cpufreq-nforce2 driver?

----------

## Hasw

@hothead: Sorry, the ATXP1 module doesn't support the K7NCR18D, this was a wrong entry (or they have different revisions, don't know yet). However the nforce2-smi module will support it.

@dob: Ondemand is not yet supported.

@mikeraach: I'll add a module patch to set the maximum FSB via module option (as initially, but it was removed).

Alexej has written a Python-script to change FSB and voltage on demand: http://www.lextech.net/work/autoFreq/

----------

## bgradid

I've followed the directions to the letter, but, I'm not having any luck changing the frequency, I run this

```
bash-2.05b# echo 1700000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed

bash-2.05b# cat /proc/cpuinfo | grep MHz

cpu MHz         : 1469.882

```

I'm running an nf7-s and a 1700+ anything I could be doing wrong?

----------

## Hasw

What are scaling_max_freq and scaling_min_freq saying? If you not have overclocked your CPU you will not get more than 1470 MHz, because this is the frequency of a 1700+.

----------

## michael3

hello

I got an error Message:

-bash: /sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed: Keine Berechtigung  (no permission)

Yes, I have executed it as root.

I've got an Asus A78X-E Board with Nforce 2. The FSB and the Volt are displayed without problems.

ls /sys/devices/system/cpu/cpu0/cpufreq

affected_cpus     cpuinfo_max_freq  scaling_available_governors  scaling_driver    scaling_max_freq

cpuinfo_cur_freq  cpuinfo_min_freq  scaling_cur_freq             scaling_governor  scaling_min_freq

Thank you!

----------

## Hasw

Have you checked the file permissions?

```

ls -la /sys/devices/system/cpu/cpu0/cpufreq/

total 0

drwxr-xr-x  2 root root    0 Mar 26 14:56 .

drwxr-xr-x  3 root root    0 Mar 26 15:31 ..

-r--r--r--  1 root root 4096 Mar 26 18:06 affected_cpus

-r--------  1 root root 4096 Mar 26 18:06 cpuinfo_cur_freq

-r--r--r--  1 root root 4096 Mar 26 18:06 cpuinfo_max_freq

-r--r--r--  1 root root 4096 Mar 26 18:06 cpuinfo_min_freq

-r--r--r--  1 root root 4096 Mar 26 18:06 scaling_available_governors

-r--r--r--  1 root root 4096 Mar 26 14:34 scaling_cur_freq

-r--r--r--  1 root root 4096 Mar 26 18:06 scaling_driver

-rw-r--r--  1 root root 4096 Mar 26 18:06 scaling_governor

-rw-r--r--  1 root root 4096 Mar 26 18:06 scaling_max_freq

-rw-r--r--  1 root root 4096 Mar 26 18:06 scaling_min_freq

-rw-r--r--  1 root root    0 Mar 26 14:56 scaling_setspeed

```

And whats the output of the kernel log (dmesg | grep cpufreq)? Is the frequency and multiplier correctly detected?

----------

## michael3

Hello

I don't have the File

 "-rw-r--r--  1 root root    0 Mar 26 14:56 scaling_setspeed".

The File is missing.The other file permissions are correct. I have only 10 Files and you have got 11 Files.

 *Quote:*   

>  bash-2.05b# lsmod
> 
> Module                  Size  Used by
> 
> w83781d                33128  0
> ...

 

 *Quote:*   

> bash-2.05b# dmesg | grep cpufreq
> 
> cpufreq: Detected nForce2 chipset revision C1
> 
> cpufreq: FSB changing is maybe unstable and can lead to crashes and data loss.
> ...

 

 *Quote:*   

> 
> 
> i2c /dev entries driver
> 
> atxp1 1-0037: Using VRM: 9.0
> ...

 

Yes, the frequenz and the multiplier are correct detected

I have also compiled in the patch in an 2.6.11.5 nitro2 Kernel.

 *Quote:*   

> bash-2.05b# cat scaling_available_governors
> 
> performance

 

Thanks!

----------

## bgradid

 *Hasw wrote:*   

> What are scaling_max_freq and scaling_min_freq saying? If you not have overclocked your CPU you will not get more than 1470 MHz, because this is the frequency of a 1700+.

 

I've also tried ranges from 90000 (my minimum reported) and the 1470 , nothing happened.

----------

## Hasw

 *michael3 wrote:*   

> Hello
> 
> I don't have the File
> 
>  "-rw-r--r--  1 root root    0 Mar 26 14:56 scaling_setspeed".
> ...

 

You need the userspace governor, then you will get scaling_setspeed.

Kernel config:

```

CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE=y

CONFIG_CPU_FREQ_GOV_PERFORMANCE=m

CONFIG_CPU_FREQ_GOV_POWERSAVE=m

CONFIG_CPU_FREQ_GOV_USERSPACE=y

```

----------

## Hasw

 *bgradid wrote:*   

> 
> 
> I've also tried ranges from 90000 (my minimum reported) and the 1470 , nothing happened.

 

Are you sure it's 90000, not 900000? 90000 would be 90 MHz CPU speed. Also 1470 should be 1470000.

The cpufreq-interface needs the values in kHz.

Try 1200000 and 1300000, or cat scaling_min_freq > scaling_setspeed and check then /proc/cpuinfo.

----------

## bgradid

no luck so far  :Sad:  I tried overclocking it in the bios a bit to see if it needed to be 'nudged'

```

bash-2.05b# cd /sys/devices/system/cpu/cpu0/cpufreq/ 

bash-2.05b# cat scaling_max_freq 

1586500

bash-2.05b# cat scaling_min_freq

1111500

bash-2.05b#  echo userspace > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor 

bash-2.05b# echo 1200000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed          

bash-2.05b# cat /proc/cpuinfo | grep MHz

cpu MHz         : 1586.945

bash-2.05b# cat scaling_min_freq > scaling_setspeed

bash-2.05b# cat /proc/cpuinfo | grep MHz

cpu MHz         : 1586.945

```

----------

## Hasw

Can you please run 

```
dmesg | grep cpufreq; egrep 'CPU_?FREQ' /usr/src/linux/.config
```

 and post the output?

----------

## bgradid

```

bash-2.05b# dmesg | grep cpufreq; egrep 'CPU_?FREQ' /usr/src/linux/.config

cpufreq: Detected nForce2 chipset revision C1

cpufreq: FSB changing is maybe unstable and can lead to crashes and data loss.

cpufreq: FSB currently at 167 MHz, FID 9.5

CONFIG_CPU_FREQ=y

# CONFIG_CPU_FREQ_DEBUG is not set

# CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE is not set

CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE=y

# CONFIG_CPU_FREQ_GOV_PERFORMANCE is not set

# CONFIG_CPU_FREQ_GOV_POWERSAVE is not set

CONFIG_CPU_FREQ_GOV_USERSPACE=y

# CONFIG_CPU_FREQ_GOV_ONDEMAND is not set

# CONFIG_CPU_FREQ_TABLE is not set

CONFIG_X86_CPUFREQ_NFORCE2=m

```

[/code]

----------

## michael3

 *Quote:*   

> 
> 
> You need the userspace governor, then you will get scaling_setspeed.
> 
> Kernel config:
> ...

 

Thanks, it works without any problems!

----------

## bgradid

bump, any idea why I can't change my frequency?

----------

## micmac

Hi all,

I'm not sure yet but I think disabling C1 Disconnect while using cpufreq_nfoce2 and atxp1 is a good idea and makes the whole setup more stable.

I've made an init-script for autocpufreq. If you want to use it be warned there's no guarantee and you have to adapt the numbers/paths and also check if autocpufreq.py fits your system (thx to woZa). Also the script needs the modules already to be loaded. 

/etc/init.d/autocpufreq

#!/sbin/runscript

depend() {

        after localmount

}

start() {

        ebegin "Starting autocpufreq"

        echo `cat $VCORE` > $OLDVCORE

        echo $MAXVCORE > $VCORE

        echo $(( $MINFSB * $FID * 100)) > $CPUFREQ/scaling_setspeed

        echo $MINVCORE > $VCORE

        start-stop-daemon       --start \

                                --background \

                                --make-pidfile \

                                --pidfile $PIDFILE \

                                --exec $DAEMON

        eend $? "Failed to start autocpufreq."

}

stop() {

        ebegin "Stopping autocpufreq"

        start-stop-daemon --stop --pidfile $PIDFILE

        rm $PIDFILE

        echo $(( $MINFSB * $FID * 100)) > $CPUFREQ/scaling_setspeed

        echo `cat $OLDVCORE` > $VCORE

        echo $(( $BOOTFSB * $FID * 100)) > $CPUFREQ/scaling_setspeed

        eend $? "Failed to stop autocpufreq"

}

/etc/conf.d/autocpufreq

# daemon to start

DAEMON=/usr/local/bin/autoCpuFreq.py

PIDFILE=/var/run/autocpufreq.pid

OLDVCORE=/var/run/autocpufreq-oldVCore

#

# ! adjust values !

#

BOOTFSB=133

MAXFSB=133

MAXVCORE=1600

MINFSB=70

MINVCORE=1100

FID=110

VCORE=/sys/bus/i2c/devices/5-0037/cpu0_vid

CPUFREQ=/sys/devices/system/cpu/cpu0/cpufreqLast edited by micmac on Wed Mar 30, 2005 4:55 pm; edited 3 times in total

----------

## woZa

Good work micmac. That script works a treat for me now...  :Cool: 

Don't forget to change the autocpufreq.py file to suite your own needs... Unlike me! Lots of head scratching. I am sure I had done it once already!

----------

## micmac

 *woZa wrote:*   

> Good work micmac. That script works a treat for me now... 
> 
> Don't forget to change the autocpufreq.py file to suite your own needs... Unlike me! Lots of head scratching. I am sure I had done it once already!

 

Thx!

What about MAXtemp in the .py-script? Per default it shows true degrees celsius. But I get (true degree celsius * 1000) while doing this:

cat /sys/bus/i2c/devices/4-0290/temp2_input

36000

cat /sys/bus/i2c/devices/4-0290/temp1_input

33000

Should I use something like 

MAXtemp=[ 50, 40]

BUFtemp=[  3,  2]

Or should I use 

MAXtemp=[ 50000, 40000]

BUFtemp=[  3000,  2000]

?

Cheers

mic

----------

## woZa

```
MAXtemp=[ 55, 39]

BUFtemp=[  3,  2]
```

is how I have mine... Haven't tested these yet though. Will give it a go and let you know.

[Edit]  -  Max temp on cpu works fine. hits the value and lowers the fsb and voltage straight away. [/Edit]

----------

## micmac

Btw without C1 Disconnect my system doesn't freeze with atxp1/cpufreq_nforce2 (well, until now at least  :Wink: ). Furthermore C1 Disconnect seems redundant while using atxp1/cpufreq_nforce2, the analog out of my soundcard sounds much better without it and my system doesn't feel laggy anymore while running at low speed (1.1V & 770MHz here).

Cheers

mic

----------

## PrakashP

C1 Halt disconnect is not redundant, but with lower frqu the effect is also lower.

----------

## woZa

Big thanks to Hasw (the modules), alexejfink (autocpufreq) and micmac (startup scripts). I now have a system that automagically increases/decreases cpu speed and vcore depending on cpuload. Ranges from 1.4Ghz @ 1.1v to 2.5Ghz @ 1.75v.

Now when my new powerbook arrives, this desktop system will become my new server.

All that I need now of for hasw to get off his a*se and write a vdimm module!  :Wink: 

----------

## Dreameen

```
 LD      init/built-in.o

  LD      vmlinux

drivers/built-in.o(.text+0x8af66): In function `atxp1_detect':

: undefined reference to `i2c_which_vrm'

drivers/built-in.o(.text+0x8ae7e): In function `atxp1_attach_adapter':

: undefined reference to `i2c_detect'

make: *** [vmlinux] Error 1

==> ERROR: Build Failed.  Aborting...

```

...and the kernel compilation stops. Any idea how to fix this? I've patched the kernel with atxp1-0.6.patch and i2c-vid-vrm90.patch.

----------

## woZa

Using atxp1-0.3 here. Works fine. Undefined symbol reference with 0.6

----------

## Dreameen

 *woZa wrote:*   

> Using atxp1-0.3 here. Works fine. Undefined symbol reference with 0.6

 

atxp1-0.3 works for me as well. I've stumbled across some problems with the autocpufreq thingy now:

```

Traceback (most recent call last):

  File "./autoCpuFreq.py", line 373, in ?

    main()

  File "./autoCpuFreq.py", line 326, in main

    cpufreq = CpuFreqInterface( file_vcore, FID, FSB_vCore)

  File "./autoCpuFreq.py", line 228, in __init__

    self.checkIntegrity()

  File "./autoCpuFreq.py", line 251, in checkIntegrity

    raise RuntimeError, "FSB_vCore pair has invalid FSB-entry"

RuntimeError: FSB_vCore pair has invalid FSB-entry

```

----------

## micmac

Hi!

At last I think I've found what was really causing the freezing. I have to set the CPU frequency setting to a specific value instead of auto in my bios in order for the atxp1 driver to be able to change the voltage. I had set it to 1600, because I thought my 1700+ defaults to 1,6V when running at full speed. Then I came about this page and it seems there are also 1700+ cpus using only 1,5V. So I set the VCore in the bios the 1500 instead and I've never had a freeze since. For now I've 

```
append="elevator=deadline cpufreq_nforce2.min_fsb=60"
```

 in my /etc/lilo.conf, 

```
echo 660000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed

echo 1100 > /sys/bus/i2c/devices/2-0037/cpu0_vid
```

 in my /etc/conf.d/local.start and 

```
echo 1500 > /sys/bus/i2c/devices/2-0037/cpu0_vid

echo 1463000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed
```

 in my /etc/conf.d/local.stop and it works. With 1500 it doesn't matter if I en- or disable C1 Disconnect (STPGNT) in the bios. But I disable it anyway, allthough my cpu gets even cooler with it being enabled, because it produces a little noise at my soundcards analog output. 

Cheers

micmac

----------

## mikeraach

Does anyone know why my NF7-S board would create prime errors (and program crashes) after changing only a mere 100mhz (10fsb)?

I've tried different bios's and all result with the same thing.

----------

## PrakashP

I made a patch to cpufreqd to switch Vcore, too. I called it "nvfreqd", which you can find here: http://punnoor.de

----------

## micmac

 *PrakashP wrote:*   

> I made a patch to cpufreqd to switch Vcore, too. I called it "nvfreqd", which you can find here: http://punnoor.de

 

Thanks!

Works here. Does is change vcore before frequency when speed is increased and the other way around when speed is lowered?

Cheers

mic

----------

## PrakashP

Of course.  :Smile: 

----------

## micmac

HI PrakashP!

Thanks. But something is wrong on my system. I have 3 different freq/vcore modes. But while doing something cpu intensive cpufreqd doesn't switch to max_power.

```
[General]

pidfile=/var/run/cpufreqd.pid

poll_interval=1

pm_type=acpi #(acpi, apm or pmu)

# Uncomment the following line to enable ACPI workaround (see cpufreqd.conf(5))

# acpi_workaround=1

vcore_path=/sys/bus/i2c/devices/6-0037/cpu0_vid

vcore_default=1500

verbosity=4 #(if you want a minimal logging set to 5)

[Profile]

name=max_power

minfreq=1463000

maxfreq=1463000

vcore=1500

policy=userspace

[Profile]

name=med_power

minfreq=1188000

maxfreq=1188000

vcore=1350

policy=userspace

[Profile]

name=min_power

minfreq=913000

maxfreq=913000

vcore=1200

policy=userspace

[Rule]

name=min

cpu_interval=0-40

profile=min_power

[Rule]

name=med

cpu_interval=30-70

profile=med_power

[Rule]

name=max

cpu_interval=60-100

programs=oggenc,mencoder

profile=max_power
```

Like when I encode music the med_power setting is applied. I'd think cpufreqd would switch to max_power because the encoder takes every bit of cpu it can get. Even 

```
programs=oggenc,mencoder
```

 doesn't help. Any idea?

While using oggenc I get this instead:

```
cat scaling_min_freq cpuinfo_max_freq cpuinfo_min_freq scaling_setspeed

1188000

1232000

1463000

913000

913000
```

I mean this is weired. First of, it should be max_power. Then scaling_min_freq and scaling_max_freq should be the same. And when both are set to 1188000 and 1232000 why is the actual cpu frequency set to 913000? 

Cheers

mic

Cheers

mic

----------

## PrakashP

I also had troubles with policy userspace. Try performance. But the target freq will deviate from your stettings, so you need to do trial and error.

Oh, if you want max_power every time with your progs, set cpu to 0-100 and maybe make a seperate rule for max for dynamic adjust.

----------

## micmac

Hi!

I've found out why it didn't get full speed while encoding. oggenc was 'niced'. Putting niceness to 0 was the solution. Now it goes all the way up.

I also tried switching the governor to performance. But the mid_power setting still uses different scaling_min_freq and scaling_max_freq from time to time. Well, I guess I got to live it or ask somebody on the lkml, because I take it it's a kernel thing that has nothing to do with cpufreqd.

Anyway

Thank!

mic

----------

## micmac

Hi again,

on the other hand switching frequencies manually works fine. I don't even have to bother with scaling_setspeed while echoing the same number into scaling_max_freq and scaling_min_freq. So it seems more likely that cpufreqd echoes the number 1232000, allthough I never wrote this number in its config file. With 

```
minfreq=1188000

maxfreq=1188000
```

I want cpufreq (nvfreq) to echo 1188000 into scaling_max_freq and scaling_min_freq, not 1232000  :Smile: 

Cheers

mic

----------

## PrakashP

I also observed the thing with niceness. Nevertheless my suggestion would help and you could still nice the process.

----------

## Dreameen

Hm, the atxp module doesn't compile cleanly with the newest stable kernel 2.6.12

Here are the errors:

```

LD      init/built-in.o

LD      vmlinux

drivers/built-in.o(.text+0x8fee0): In function `atxp1_detect':

: undefined reference to `i2c_which_vrm'

drivers/built-in.o(.text+0x8fdf6): In function `atxp1_attach_adapter':

: undefined reference to `i2c_detect'

make: *** [vmlinux] Błąd 1

==> ERROR: Build Failed.  Aborting...

```

I didn't know who to contact, but maybe the author of atxp patch is reading this board and he could fix things up.

----------

## Hasw

Which version of the ATXP1 module are you using? Are you using the kernel patch? It should be fixed, otherwise it

doesn't cleanly work with 2.6.12. Also the i2c-vid-vrm90.patch needs to be applied. 

Can you please PM or mail me: 

```

grep I2C kernelsource/.config

grep SENSORS kernelsource/.config

```

The module is missing the two functions i2c_which_vrm and i2c_detect, which are there in 2.6.12. So it's possible that

it hasn't compiled in the i2c_sensor functions (is I2C enabled in your kernel config).

Also the ATXP1 module is in 2.6.12-rc6, it waits to get merged with the stable kernel.

----------

## Dreameen

Sorry for the delay. I'm using arch linux so I visit gentoo forums occasionally. now, let's see:

 *Hasw wrote:*   

> Which version of the ATXP1 module are you using?

 

I've tried 2 versions of the module, atxp1-0.3 and atxp1-0.6 and both failed.

 *Quote:*   

> Are you using the kernel patch? It should be fixed, otherwise it
> 
> doesn't cleanly work with 2.6.12.

 

Yes, I was patching the kernel. In this case I'll wait for the fix before upgrading to 2.6.12

 *Quote:*   

> The module is missing the two functions i2c_which_vrm and i2c_detect, which are there in 2.6.12. So it's possible that
> 
> it hasn't compiled in the i2c_sensor functions (is I2C enabled in your kernel config).

 

All the I2C specific options were enabled properly. I was using a working .config from a previous kernel compilation as a base.

 *Quote:*   

> Also the ATXP1 module is in 2.6.12-rc6, it waits to get merged with the stable kernel.

 

Good news, but when is it going to happen...

----------

## Dreameen

Any progress on fixing the patch???

----------

## PrakashP

You could try kernel 2.6.13-rc1, as well.

----------

## Dreameen

I've just tried it and the same thing happens:

```

LD      init/built-in.o

  LD      vmlinux

drivers/built-in.o(.text+0x92298): In function `atxp1_detect':

: undefined reference to `i2c_which_vrm'

drivers/built-in.o(.text+0x921ae): In function `atxp1_attach_adapter':

: undefined reference to `i2c_detect'

make: *** [vmlinux] Błąd 1

==> ERROR: Build Failed.  Aborting...

```

----------

## Dreameen

Hi again,

I had posted the problem on linux-kernel mailing list and they've come up with a patch that fixes the issue.

atxp1.patch:

```

--- linux-2.6.12-mm2-full/drivers/i2c/chips/Kconfig.old 2005-06-30 23:56:34.000000000 +0200

+++ linux-2.6.12-mm2-full/drivers/i2c/chips/Kconfig     2005-06-30 23:57:08.000000000 +0200

@@ -80,6 +80,7 @@

 config SENSORS_ATXP1

        tristate "Attansic ATXP1 VID controller"

        depends on I2C && EXPERIMENTAL

+       select I2C_SENSOR

        help

          If you say yes here you get support for the Attansic ATXP1 VID

          controller.

```

Enjoy.

----------

## PrakashP

Ja ja, my patch was 6 minutes too late to Adrian...

----------

## BetterUnborn

I finally found what I've been looking for ... thx hasw

Now I'm able to run my desktop system without any fan noise at all  :Cool: 

Will there be any chance that this is ported to other chipsets? 

This could be very useful for the Intel Centrino fraction ... though advanced speedstep reduces cpu voltage, default settings are far too conservative. Linux on laptops tends to be much louder than windows; there you have many tools to tweak and fine-adjust.

----------

## yemu

hi!

i have a problem with atxp1 module on 2.6.11-r9

here's the compilation output (i tried to compile atxp1 in a separate directory, and didn't patch the kernel)

```

komputerek atxp1-0.6 # make

make -C /lib/modules/2.6.11-gentoo-r9/build SUBDIRS=/home/yemu/programs/atxp1-0.6 modules

make[1]: Entering directory `/usr/src/linux-2.6.11-gentoo-r9'

  CC [M]  /home/yemu/programs/atxp1-0.6/atxp1.o

/home/yemu/programs/atxp1-0.6/atxp1.c: In function `atxp1_storevcore':

/home/yemu/programs/atxp1-0.6/atxp1.c:130: warning: implicit declaration of function `reg_from_vid'

  Building modules, stage 2.

  MODPOST

*** Warning: "reg_from_vid" [/home/yemu/programs/atxp1-0.6/atxp1.ko] undefined!

  CC      /home/yemu/programs/atxp1-0.6/atxp1.mod.o

  LD [M]  /home/yemu/programs/atxp1-0.6/atxp1.ko

make[1]: Leaving directory `/usr/src/linux-2.6.11-gentoo-r9'

komputerek atxp1-0.6 # make install

make -C /lib/modules/2.6.11-gentoo-r9/build SUBDIRS=/home/yemu/programs/atxp1-0.6 modules

make[1]: Entering directory `/usr/src/linux-2.6.11-gentoo-r9'

  Building modules, stage 2.

  MODPOST

*** Warning: "reg_from_vid" [/home/yemu/programs/atxp1-0.6/atxp1.ko] undefined!

make[1]: Leaving directory `/usr/src/linux-2.6.11-gentoo-r9'

mkdir -p /lib/modules/`uname -r`/kernel/drivers/i2c/chips

cp ./atxp1.ko /lib/modules/`uname -r`/kernel/drivers/i2c/chips

depmod -a

komputerek atxp1-0.6 # modprobe atxp1

FATAL: Error inserting atxp1 (/lib/modules/2.6.11-gentoo-r9/kernel/drivers/i2c/chips/atxp1.ko): Unknown symbol in module, or unknown parameter (see dmesg)

komputerek atxp1-0.6 # dmesg | grep atxp1

atxp1: Unknown symbol reg_from_vid

```

what do I do wrong?

----------

## yemu

i managed to get frequency and vcore scaling to work with atxp1 v0.3, 2.6.11-gentoo-r9 and nvfreqd (from punnoor.de)  :Smile:  it works like a charm - my mean CPU (2200XP@1970Mhz WaterCooled) temperature droped from 46 to 40 degrees celsius (which is 13 degrees more then ambient temperature) during normal computer usage (X, OOorg, KDE, Amarok, Azureus, Skype, superkaramba). i'm really happy because in a couple of days i plan to install watercooling on a northbridge and my gf5600 and completly get rid of the noise (abit nf7-s fan is sooooo loud).

One thing i don't like about nvfreqd is a vcore limit - anyone knows where to change something in the code in order to get rid of the limitation?

also, hasw, do you plan to add memory and northbridge voltage support?

best regards

PS. thanks for the great piece of software.

----------

## PrakashP

The limit is hw related, so w/o mod, no dice.

----------

## frary

I have problems loading the module:

```
modprobe cpufreq-nforce2

FATAL: Error inserting cpufreq_nforce2 (/lib/modules/2.6.11-ck10n/kernel/arch/i386/kernel/cpu/cpufreq/cpufreq-nforce2.ko): Unknown symbol in module, or unknown parameter (see dmesg)
```

Relevant part of the ck-2.6.11-r10 Kernel:

```
# CPU Frequency scaling

#

CONFIG_CPU_FREQ=y

# CONFIG_CPU_FREQ_DEBUG is not set

CONFIG_CPU_FREQ_STAT=y

# CONFIG_CPU_FREQ_STAT_DETAILS is not set

# CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE is not set

CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE=y

CONFIG_CPU_FREQ_GOV_PERFORMANCE=y

CONFIG_CPU_FREQ_GOV_POWERSAVE=y

CONFIG_CPU_FREQ_GOV_USERSPACE=y

CONFIG_CPU_FREQ_GOV_ONDEMAND=y

CONFIG_CPU_FREQ_TABLE=y

#

# CPUFreq processor drivers

CONFIG_X86_CPUFREQ_NFORCE2=m
```

Chipset is nforce4-ultra400 on an Abit NF7-S2G

I would really like to use FSB-Scaling, any ideas what I did wrong?

T

----------

## yemu

you said that your mobo is abit-nf7-s2g - s2 is a completly different motherboard which is not supported. s2 board doesn't allow explicit vcore changing even in bios (you can only add 5% or 10% for example). this board also doesn't support FID changing.

----------

## frary

You are right, there seems to be no atxp1 chip on my board. But I got dynamic FSB working ( the module loads fine after having corrected the Grub-Syntax to load the correct kernel! ).

I tried different demons ( cpudyn, powernowd, cpufreqd ) but 1500 ( @FSB100 ) seems to be the lowest stable setting.

Prime runs fine at 1250 ( @FSB83 ), but I cannot switch back to 2000 ( @133 ) without freezing my system.

So for the Abit NF7-S2G FSB-throttling seems to work between 100 and 133.

@yemu: Do you know that board? I´m searching for the Faneq feature since I bought it, but there seems to be no possibility to control the fans...

T

EDIT: With C1 disconnect enabled, my system freezes when changing FSB. Should have bought a S939 with athlon 64 for powersaving & Fancontrol...

----------

## yemu

actually, i don't know much about this board - I own nf7-s, i also considered s2 but since it doesn't allow to change the multiplier i bought nf7-s.

now I encountered strange problems with my new Xp-M 2500+ - it doesn't want to go below 1900-2000Mhz (started at 2300 - 200x11,5). it's a little better when i boot with fsb166. on the same board my old 2200+ it worked from ~1250 to 1950 (cpu booted at 1950 13,5x145). so it seems it's cpu fault... if anyone encountered similiar problem and was able to fix it - please help - i'm using 2.6.11-gentoo-r9, today i'll try 2.6.12-gentoo-r4 - maybe this will help, but honestly i doubt it...

also i think it would be great if there was possible to increase fsb not only decrease it below the value set in bios.

----------

## frary

 *yemu wrote:*   

> actually, i don't know much about this board - I own nf7-s, i also considered s2 but since it doesn't allow to change the multiplier i bought nf7-s.

 

Are you able to control your Fanspeeds via BIOS? Example Screens on Abit Homepage show a FanEQ option which allows to set Temperatures and Fanspeed ratios, but even after flashing the latest BIOS I cannot find that option!!!!

What is your approach for Frequency-scaling? I´m testing powernowd again with steps of 50000 and the sine Mode which seems to work between 1250 and 2000...

T

Edit: System freezed! Iwas able to start and stop prime several times, but it seems that with any setting/demon/governor scaling sometimes fails.

Withiout FSB-scaling the system is rock-solid!

----------

## yemu

 *frary wrote:*   

>  *yemu wrote:*   actually, i don't know much about this board - I own nf7-s, i also considered s2 but since it doesn't allow to change the multiplier i bought nf7-s. 
> 
> Are you able to control your Fanspeeds via BIOS? Example Screens on Abit Homepage show a FanEQ option which allows to set Temperatures and Fanspeed ratios, but even after flashing the latest BIOS I cannot find that option!!!!
> 
> 

 

i'm not sure because i haven't tried it

 *frary wrote:*   

> 
> 
> What is your approach for Frequency-scaling? I´m testing powernowd again with steps of 50000 and the sine Mode which seems to work between 1250 and 2000...
> 
> 

 

with my old cpu (2200+) i used nvfreq (cpufreq patched to allow also vcore changes) and it worked flawlessly. now i only change fsb and vcore manually trying to figure out the limits. i made changes in small 10000 steps it doesn't change anything - system freezes at 1900000. 

what cpu do you use?

----------

## frary

2400+ TBred B at 133*15=2000. As the Abit was new ( bought monday ), I took it back an switched to ASUS A7N8x-E Deluxe.

Please don`t tell me this board is even worse, because I won`t change it again.

New trial, new luck! As soon as I got my Installation set up for this board I will be back with another try ( this time I will be able to change the multi! ).

T

----------

## ahorn

it's fine to chance the fsb, but this is more ineffective for me (sempron 2500+) because i can switch from 1,4GHz to 1,75GHz (this doesnt make a big difference). So it would be better to got a cpufreqd-patch with multiplikator-support, because i can lower my speed more then with the fsb-method. also, at the new nforce2 ultra ssp (mcp2), there's cpu/ram asynchron so at last you only touch the cpu-fsb. that's why a fid-based solution would be nice.

and is it possible to get the SMI-module even it is in beta-stage? 

best wishes, ahorn.

----------

## PrakashP

I updated nvfreqd: nvclock is now integrated. :Cool: 

----------

## woZa

This worked great on my 8rda+ (1.1) all the way down to at least 113 fsb (didn't need to go any lower) and 1.1v. I have now bought an nf7-s and am having issues when I raise the voltage. It will drop down fine but hangs on any voltage increase. This happens with 8rdavore-0.8.8-dev8 on windoze too.

Also can't compile atxp1 anymore - could be because I am now running 2.6.12 kernel. Worked fine on 2.6.11 kernel. Not at home so can't give error message. Will update later when I have tested a bit more.

<edit>Have just seen the top post on this page with regard to 2.6.12. Will try the patch later</edit>

<edit>No luck with the patch but got v 0.3 compiled ok. Still no luck with raising the vcore. Still crashing. Anyone else having problems with nf7-s v2 or do others have it working ok with this mobo???</edit>

----------

## Schmolch

I have a problem right at the beginning.

I rebooted the new kernel (2.6.12-gentoo) but i am unable to echo anything into the /sys/.../cpufreq/ files.

Im root and the files are -rw- but it wont echo anything into it.

When i try to edit them with vim i get this error trying to write the changes:

```
"scaling_governor" E667: Fsync failed
```

[update] its working now, i had to set it to userspace in the kernel-config.

I can set the FSB down to 66MHz now on my 8rda+ = Athlon 900MHz (max OC is 2200)  :Smile: 

----------

## bgradid

I don't understand it. I've tried two seperate nf7-s motherboards (rev. 2.0) with a total of 3 different bioses (and now the newest available)

no matter what I do, I can't adjust the CPU speed.

I follow the guide too the letter but when I do 

```
echo 1700000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed

```

and get my cpu info from /proc/cpuinfo, nothing has changed. At all.

I tried it a few months ago with the same problem.

1700000 is well within my 'min-max' level.

cpufreqd output is fine too when the module is loaded

```
cpufreq: Detected nForce2 chipset revision C1

cpufreq: FSB changing is maybe unstable and can lead to crashes and data loss.

cpufreq: FSB currently at 171 MHz, FID 13.0

```

I don't have a clue right now   :Evil or Very Mad: 

There are no error messages when I try to change my cpu speed either.   :Confused: 

edit: i'm using ck-sources version 2.6.11-ck10     

the last time it was a gentoo-sources kenrel of some kind.. 2.6.9 or something

----------

## Hasw

The BIOS doesn't matter. Can you please post 

```
cat /sys/devices/system/cpu/cpu0/cpufreq/*
```

 and enable cpufreq debugging in kernel to check messages?

----------

## bgradid

#cat /sys/devices/system/cpu/cpu0/cpufreq/*

0

1989000

2223000

1573000

userspace performance

1989000

nforce2

userspace

2223000

1573000

1989000

I'll get on debug messages in a minute

----------

## stealth_br

Is there anyway to change vcore for ASUS A7N8X-E DELUXE ?

At windows i found 8RDAVcore great , i can get 1.425 vcore  :Smile: 

But i barely  use windows , so i need a tool for linux.

I saaw a gay talking about a SMI modules but i can't find this module anywhere.

----------

## Jinidog

My nforce2-board (N2U400) can bring the clock down, but not bring it up again.

It freezes when I try so.

Has someone a hint?

----------

## Jase

Cpufreq seems to work nicely or atleast I think so. When I set my fsb to minimum the CPU MHz in /proc/cpuinfo doesn't update, but the bogomips drop 4400 to 3300. So I think it works.

On the other hand atxp1 doesn't work at all. I get kernel oops when trying to change the voltage. Dmesg shows this when I load the atxp1 modules "atxp1 2-004e: Using VRM: 9.0" There's no " .... atxp1: Detected on SMBus nForce2 adapter at 5000, address 0x37" like in the first post of this thread.

I use 2.6.13.2-nitro1 kernel and atxp1-0.6.

Here's the oops

```
Unable to handle kernel paging request at virtual address 30353631

 printing eip:

b019e953

*pde = 00000000

Oops: 0000 [#1]

PREEMPT SMP

Modules linked in: atxp1 ppp_synctty ppp_async crc_ccitt ppp_generic slhc w83781d i2c_sensor i2c_isa cpufreq_nforce2 i2c_nforce2 spca5xx budget_av saa7146_vv video_buf v4l1_compat v4l2_common videodev budget_core dvb_core saa7146 ttpci_eeprom stv0299 tda10021 tda1004x firmware_class nvidia shfs

CPU:    0

EIP:    0060:[<b019e953>]    Tainted: P      VLI

EFLAGS: 00210246   (2.6.13.2-nitro1)

EIP is at sysfs_readdir+0xb3/0x230

eax: 00000000   ebx: ea189d5c   ecx: ffffffff   edx: ea189d58

esi: ea189d58   edi: 30353631   ebp: 30353631   esp: de449f30

ds: 007b   es: 007b   ss: 0068

Process bash (pid: 8682, threadinfo=de448000 task=da0d1aa0)

Stack: ea189d58 b04f2b02 00000002 00000001 00000000 000027b9 00000004 ea189bd4

       00000000 ea189d0c d4bdb7e8 cdcad4c0 fffffffe cdcad4c0 b0175909 cdcad4c0

       de449fa0 b0175bf0 00001000 08127f0c fffffff7 b0175d62 cdcad4c0 b0175bf0

Call Trace:

 [<b0175909>] vfs_readdir+0x79/0xa0

 [<b0175bf0>] filldir64+0x0/0xf0

 [<b0175d62>] sys_getdents64+0x82/0xe2

 [<b0175bf0>] filldir64+0x0/0xf0

 [<b01031ab>] sysenter_past_esp+0x54/0x75

Code: 75 16 8b 1b 39 5c 24 1c 75 ee 83 c4 28 31 c0 5b 5e 5f 5d c3 8d 74 26 00 89 34 24 e8 28 e5 ff ff 89 c5 b9 ff ff ff ff 31 c0 89 ef <f2> ae f7 d1 49 89 4c 24 20 8b 46 20 85 c0 0f 84 42 01 00 00 8b

```

Here's the compiler errors

```
make -C /lib/modules/2.6.13.2-nitro1/build SUBDIRS=/usr/src/atxp1-0.6 modules

make[1]: Entering directory `/usr/src/linux-2.6.13.2-nitro1'

  CC [M]  /usr/src/atxp1-0.6/atxp1.o

/usr/src/atxp1-0.6/atxp1.c:169: warning: initialization from incompatible pointer type

/usr/src/atxp1-0.6/atxp1.c:169: warning: initialization from incompatible pointer type

/usr/src/atxp1-0.6/atxp1.c:211: warning: initialization from incompatible pointer type

/usr/src/atxp1-0.6/atxp1.c:211: warning: initialization from incompatible pointer type

/usr/src/atxp1-0.6/atxp1.c:251: warning: initialization from incompatible pointer type

/usr/src/atxp1-0.6/atxp1.c:251: warning: initialization from incompatible pointer type

  Building modules, stage 2.

  MODPOST

  CC      /usr/src/atxp1-0.6/atxp1.mod.o

  LD [M]  /usr/src/atxp1-0.6/atxp1.ko

make[1]: Leaving directory `/usr/src/linux-2.6.13.2-nitro1'

```

And here's my kernel configs of I2C and SENSORS

```
# I2C support

CONFIG_I2C=y

CONFIG_I2C_CHARDEV=y

# I2C Algorithms

CONFIG_I2C_ALGOBIT=m

CONFIG_I2C_ALGOPCF=m

CONFIG_I2C_ALGOPCA=m

# I2C Hardware Bus support

CONFIG_I2C_ISA=m

CONFIG_I2C_NFORCE2=m

CONFIG_I2C_SENSOR=m

# Hardware Monitoring support

CONFIG_HWMON=y

CONFIG_SENSORS_EEPROM=m

CONFIG_SENSORS_ATXP1=m

CONFIG_SENSORS_IT87=m

CONFIG_SENSORS_W83781D=m

CONFIG_SENSORS_W83627HF=m

CONFIG_SENSORS_W83627EHF=m

```

----------

## Hasw

@Jinidog: What's your Boot-FSB and your lowest value?

@Jase: cpufreq should update /proc/cpuinfo...hm. The "Detected on..." message was removed. Also they changed somewhere between 2.6.11 and 2.6.12-13 the sysfs-interface ("warning: initialization from incompatible pointer type"...not good), so it will crash if someone tries to write to the device...

Have you checked if the ATXP1 module is maybe already in your kernel?

----------

## Jinidog

I have a AthlonXP 2800+.

Normally it runs with 2070 MHz and I can scale it down to 1512500 Hz.

----------

## Jase

 *Hasw wrote:*   

> Have you checked if the ATXP1 module is maybe already in your kernel?

 

Yes, it wasn't there so I patched the kernel. The patch applied with some minor changes. I'll take a look at the sysfs changes and try to solve it by my self. I just didn't know where to start from. Thanks anyway.

----------

## stealth_br

Any tool to change vcore on asus motherboard ?

atxp1 doesn't work.

----------

## stealth_br

I forgot to ask.

does anyone have  8rdavcore for linux. They released a 0.5.5 version , but after GPL problems it has disappeared and i can find nowhere.

----------

## Hasw

8rdavcore 0.5.5 was a userspace ATXP1 driver. Since there's now a ATXP1 module for the kernel the old cold isn't required any more. Maybe when I get the time I'll finish the successor of 8rdavcore, which will run on linux.

----------

## alphonsebrown

I have some problem with the kernel patches

# pwd

/usr/src/kernels/2.6.14-1.1637_FC4-i686

# patch -Np1 < atxp1-0.6.patch

patching file drivers/i2c/chips/Kconfig

Hunk #1 succeeded at 74 (offset -319 lines).

patching file drivers/i2c/chips/Makefile

Hunk #1 FAILED at 11.

1 out of 1 hunk FAILED -- saving rejects to file drivers/i2c/chips/Makefile.rej

patching file drivers/i2c/chips/atxp1.c

# patch -Np1 < i2c-vid-vrm90.patch

can't find file to patch at input line 3

Perhaps you used the wrong -p or --strip option?

The text leading up to this was:

--------------------------

|--- linux-2.6.11-rc4-mm1-orig/include/linux/i2c-vid.h  2005-02-26 16:12:23.710354080 +0100

|+++ linux-2.6.11-rc4-mm1/include/linux/i2c-vid.h       2005-02-26 16:13:27.690627600 +0100

--------------------------

File to patch:

Skip this patch? [y]

Skipping patch.

1 out of 1 hunk ignored

please any suggestions are welcome

----------

## PrakashP

2.6.14 doesn't need patching.

----------

## alphonsebrown

 *PrakashP wrote:*   

> 2.6.14 doesn't need patching.

 

wow that was fast, thank you!

edit: btw: PrakashP, I'm not good with ebuild, how can I use your cpufreq patch? http://punnoor.de/nvfreqd/nvfreqd-overlay.tar.bz2 <- is it this file? Thanks in advance!

so should  I worry about:

```

# patch -Np1 < atxp1-0.6.patch

patching file drivers/i2c/chips/Kconfig

Hunk #1 succeeded at 74 (offset -319 lines). 
```

----------

## alphonsebrown

 *micmac wrote:*   

> Btw without C1 Disconnect my system doesn't freeze with atxp1/cpufreq_nforce2 (well, until now at least ). Furthermore C1 Disconnect seems redundant while using atxp1/cpufreq_nforce2, the analog out of my soundcard sounds much better without it and my system doesn't feel laggy anymore while running at low speed (1.1V & 770MHz here).
> 
> 

 

Sorry is that C1:

```
Query Athlon powersaving mode...

[b]athcool version 0.3.11[/b] - control power-saving mode on AMD Athlon/Duron CPUs

nVIDIA nForce2 (10de 01e0) found

'Halt Disconnect and Stop Grant Disconnect' bit is enabled.
```

----------

## zensoni

Hi there

I have been playing around with cpufreq-nforce2. It has great potential, but I am not satisfied yet  :Smile: 

On my ASUS A7N8X-X, I can bring my Barton 2800+ (2083 = 12.5 * 166) down to 625Mhz. But I can not bring it up again. When I cross around 1000MHz on the way down I cannot go up again. 

Scenario: From 2083 -> 1500Mhz -> 1200Mhz -> 800Mhz -> 625Mhz -> 700 -> 800 -> 900 -> 1000 -> 1100 -> 1200 -> 1300 -> 1400 -> boom (1500)

Scenario: 2083 -> 1600 -> 1200 -> 1600 -> 2083 totally stable

Scenario: 2083 -> 1600 -> 1200 -> 1000 -> 1200 (boom)

I then tried another board. Aopen AK79D-400VN. There I can do whatever I desire, but the MHz does not go down in /proc/cpuinfo ALTHOUGH the bogomips does!!! The bogomips value gets updated, but the system remains at 2083. I then tried another CPU. Same deal. I don't get it. AK79D-400VN is listed as supported. I can see that other ppl in this thread have had simelar problems.

Any clues? Ideas? solutions? Ohh yes, stock voltage, no overclocking, no out of bounds on ram and so forth, and the latest 2.6.14.2 kernel.

Regards Thomas, Denmark

----------

## woZa

 *Hasw wrote:*   

> 8rdavcore 0.5.5 was a userspace ATXP1 driver. Since there's now a ATXP1 module for the kernel the old cold isn't required any more. Maybe when I get the time I'll finish the successor of 8rdavcore, which will run on linux.

 

That would be really good... I had all this working perfectly on my 8rda+ but have since replaced it with an abit nf7s-v2 which it won't work with (crashes when increasing voltage after lowering...)   :Sad: 

----------

## soql

Hello !! Sorry for my very poor english.

Could you tell me which version of bios you use in yours 8rda+, because on my computer (gentoo,8rda+) cpufreq works but I can change FSB only with 20Mhz. If I have default FSB on 200 and I change to 180 everything ok, but 

cpufreq-set -s 1700000 

makes my gentoo halt immidietly  :Sad:   :Sad: 

I use 2.6.14.3

----------

## anilan

Hallo,

I'm using an Epox 8RDA6+ Pro with Mobile-Barton 2500+ and changing FSB and voltage is possible and work fine, but I can't go below 1.325V. When I set Vcore to 1.300V the system hangs. I think 1.100V must be possible. What is wrong or has anybody an idea?

Thanks!

----------

## woZa

Hmmm, autocpufreq scripts lowers voltage and cpu frequency when run but never raises either again. It is as if it doesn't realise that the cpu is at 100% load... Anyone else experience this? Doing things manually seems to work ok now...

----------

## luisfeser

Anybody can change vcore in an Abit an7 mobo?

I can change the fsb, but not the vcore, so the temperature don't down

I think this is about uguru chip, that i can't see voltages or temperatures of my mobo.

----------

## luisfeser

this is the error:

i can see the vcore:

```
root@pcluisfe linux # cat /sys/bus/i2c/devices/9191-0290/driver/9191-0290/cpu0_vid

1850
```

(it's correct because overclocking)

but i can't change it

```
root@pcluisfe linux # echo 1750 > /sys/bus/i2c/devices/9191-0290/driver/9191-0290/cpu0_vid

bash: /sys/bus/i2c/devices/9191-0290/driver/9191-0290/cpu0_vid: Permiso denegado
```

Any idea?

Mi pc is an athlon xp barton mobile 2500+ @ 2000Mhz in an Abit an7, with fsb 400

----------

## parism_s

Hi, is there any way to manually change the maximum_fsb frequency so that it is above the boot_fsb? The only option I see is the min_fsb=..

I have got a shuttle an35n ultra and I want to scale from 66Mhz to 200Mhz Fsb. However if I boot at 200Mhz it only goes down to 150Mhz. If I boot at 133 Mhz I am limited to an 133Mhz maximum but can scale down to 66Mhz. Using 8rdvcore in windows only booting at 133Mhz I can scale from 66 to 200 and back without any problems. Any recommendations? Unforunately I know nothing about programming so I don't have the knowledge to modify the cpufreq-nforce2 source.

----------

## fysa

 *luisfeser wrote:*   

> this is the error:
> 
> i can see the vcore:
> 
> ```
> ...

 

Did you ever figure thisout?  I have the same issue.  9191-0290 and cpu0_vid shows 1750 but I cannot modify it.  This is a NF7-S2.

----------

## brucer

I can setup the most modules and use the cpufreq-nforce2 for changing my CPU-Speed.

If i load the modules for atxp1 it says:

cpufreq: Detected nForce2 chipset revision C1

cpufreq: FSB changing is maybe unstable and can lead to crashes and data loss.

cpufreq: FSB currently at 100 MHz, FID 10.0

i2c_adapter i2c-1: nForce2 SMBus adapter at 0x5000

i2c_adapter i2c-2: nForce2 SMBus adapter at 0x5040

in your Howto it should be like that with dmesg:

atxp1: Detected on SMBus nForce2 adapter at 5000, address 0x37 

after loading the modules I can see in the location /sys/bus/i2c/devices/9191-0290

all neccesary files and read out the /in1_input, but even with setting the file-rights correct

it is not possible to change the volt.

in my bios i set the core volt at 1.6  

on my motherboard is a chip its named attansic so i expected this to work

my linux is gentoo, kernel 2.6.16

may be anyone of yours find some mistakes here

thanks

----------

## kondzik

 *luisfeser wrote:*   

> this is the error:
> 
> i can see the vcore:
> 
> ```
> ...

 

I've had similiar problem. I couldn't change Vcore through /sys/bus/i2c/devices/9191-0290/cpu0_vid but it is possible to do that thorugh /sys/bus/i2c/devices/0-004e/cpu0_vid. I have nf7-s board but i think it doesn't matters.

----------

