PDA

View Full Version : HowTo: Undervolt your notebook CPU for longer battery life


Pages : 1 [2]

ivanhoe1024
November 14th, 2008, 10:21 AM
ok... here's a fix. from /usr/src/linux-source-2.6.27:

cp ../linux-headers-2.6.27-7-generic/Module.symvers .

before running any of the make targets. I also removed a Module.symvers from the acpi-cpufreq directory to be sure it was using the toplevel version. I followed all the other instructions and it works again. (woohoo)

To compile the module from the 2.6.27-8 sources, where do I have to take the Module.symvers? From 2.6.27-7 headers, or from the 2.6.27-8 ones?? I'm sorry, but I'm not so expert in kernel matters...

bmidgley
November 14th, 2008, 01:44 PM
the versions should probably match what you are running... to recap I had already done:

cd /usr/src/linux-source-2.6.27
patch -p1 < linux-phc*.patch

then to get it to work:

make clean
cp ../linux-headers-`uname -r`/Module.symvers .
make oldconfig
make prepare
make scripts
make M=./arch/x86/kernel/cpu/cpufreq

To compile the module from the 2.6.27-8 sources, where do I have to take the Module.symvers? From 2.6.27-7 headers, or from the 2.6.27-8 ones?? I'm sorry, but I'm not so expert in kernel matters...

ivanhoe1024
November 16th, 2008, 09:47 AM
the versions should probably match what you are running... to recap I had already done:

cd /usr/src/linux-source-2.6.27
patch -p1 < linux-phc*.patch

then to get it to work:

make clean
cp ../linux-headers-`uname -r`/Module.symvers .
make oldconfig
make prepare
make scripts
make M=./arch/x86/kernel/cpu/cpufreq

Ok, thank you a lot, I'll try all these things... If it works for me to, maybe it'll work for everyone...

skinnie
November 16th, 2008, 11:20 AM
can someone post apci-cpufreq.ko for 2.6.27-8 i386?

ivanhoe1024
November 16th, 2008, 06:20 PM
@ bmidgley: wow, it's working!! A lot of thanks, you're a monster!!=D>=D>

@skinnie: here is your modded module, but... why don't you try to compile it yourself? it doesn't take more than 5 minutes...

acpi-cpufreq for 32-bit intrepid 2.6.27-8

skinnie
November 16th, 2008, 06:41 PM
@ bmidgley: wow, it's working!! A lot of thanks, you're a monster!!=D>=D>

@skinnie: here is your modded module, but... why don't you try to compile it yourself? it doesn't take more than 5 minutes...

acpi-cpufreq for 32-bit intrepid 2.6.27-8

it's strange..in the other day I tried and I coulnd't do it,I don't know why...
thanks anyway :)

ivanhoe1024
November 16th, 2008, 07:01 PM
it's strange..in the other day I tried and I coulnd't do it,I don't know why...
thanks anyway :)

It's a pleasure, it's only the first time I can help someone in something concerning GNU/linux, so I'm very happy I can start to contribute actively to this wonderful forum!! :lolflag:

Virgofenix
November 17th, 2008, 08:52 AM
Could somebody please post the increase in their notebook's battery life from the undervolting procedure?

ivanhoe1024
November 17th, 2008, 06:05 PM
Could somebody please post the increase in their notebook's battery life from the undervolting procedure?

Uhm, Uhm :-k:-k I don't think it is the most important aspect of the phc patch... I read in this forum that the battery life doesn't change a lot... But I can tell you that my cpu temperature is lower of about 4-5 ° Celsius in idle, and about 10-15 ° Celsius during video conversion!!

ivanhoe1024
November 18th, 2008, 05:12 PM
it's strange..in the other day I tried and I coulnd't do it,I don't know why...
thanks anyway :)

Hi, I have just noticed that my module works fine until I have my AC adapter plugged in, but at the moment I'm using my laptop (asus f3sv) with the battery, and it seems that the module fails... Have you the same problem?? Can you check it for me, please??

blakjesus
November 20th, 2008, 04:20 AM
How can i compile the patch for the 64-bit version of the 2.6.27-7? I downloaded what the website said was the source code but there are already patch files for previous kernels. (I dont even know if they are even compatible with 64-bit)

Please help. I know how to compile stuff, but i have never worked with the kernel source code.

ivanhoe1024
November 25th, 2008, 08:01 PM
Here is the module compiled for 2.6.27-10 and 64 bit... It works for me, hope this can interest someone... bye :)

skinnie
November 26th, 2008, 09:23 AM
Hi, I have just noticed that my module works fine until I have my AC adapter plugged in, but at the moment I'm using my laptop (asus f3sv) with the battery, and it seems that the module fails... Have you the same problem?? Can you check it for me, please??

how do I check?

XRayA4T
November 26th, 2008, 01:38 PM
Here is a 32 bit version for 2.6.27-10

aashay
November 26th, 2008, 07:54 PM
Here is a 32 bit version for 2.6.27-10

This is the first thread I check whenever a new version is released. Too lazy to compile my own modules :)
Thanks!

Ev1L
November 27th, 2008, 02:11 PM
hey guys, you skipped 2.6.27-9 which has been just made available from update manager.
could someone take care of it please? :p

Ev1L
November 27th, 2008, 04:51 PM
did it by myself, enjoy ;)

ivanhoe1024
November 27th, 2008, 07:49 PM
how do I check?

You can turn up your laptop only with the battery, without AC adapter, and if your cpu can scaling frequencies, it's all right, instead if it can't, the module has got a bug: it works only with the laptop in AC mode, not in battery mode... I haven't tried it recently, I'm sorry... Moreover, I shifted to the 64 bit version of kubuntu, so I'm busy with some configurations...:guitar:

winnibob
November 28th, 2008, 07:26 AM
hey guys, you skipped 2.6.27-9 which has been just made available from update manager.
could someone take care of it please? :p

did it by myself, enjoy ;)

Could you tell us wether it is 32 bits or 64 bits version, because I tried it on my 32 bits Intrepid and it didn't work...

Thanks

Ev1L
November 28th, 2008, 07:44 AM
oh sorry, i forgot, it's 32bits

i cannot tell why it's not working, i used it yesterday evening and it was all like before the kernel update, also after reboots :)

Samfisher
November 28th, 2008, 08:59 AM
Could someone please either upload an acpi-cpufreq.ko module or give instructions on how to create one for
Ubuntu Intrepid kernel 2.6.27-9 64-bit ?

Thank you!

winnibob
November 28th, 2008, 11:21 AM
oh sorry, i forgot, it's 32bits

i cannot tell why it's not working, i used it yesterday evening and it was all like before the kernel update, also after reboots :)

I tried several time with your module, but it really doesn't work for me. So I compiled it myself and now it works perfect.
I post my file here in case people have trouble or just wanna check.
The module has been compiled for kernel 2.6.27-9 on a 32 bits Intrepid.

Schnitzelpudding
November 28th, 2008, 11:53 AM
Thanks winnibob, that one works for me as well.

Ev1l: Your module failed to load with a "acpi_cpufreq: disagrees about version of symbol struct_module" syslog message.

Ev1L
November 28th, 2008, 12:00 PM
mh ok, i cannot explain it but i am glad that you were able to compile it yourself.
in case of bad surprise tonight when i'll go home, i'll try yours ;)

Samfisher
November 29th, 2008, 10:29 PM
Still no 64-bit module for 2.6.27-9? :(

Mizzou_Engineer
November 29th, 2008, 10:45 PM
Hey guys,

I have a T5870 and my fids are:

root@x64ubuntu8041:~# cat /sys/devices/system/cpu/cpu0/cpufreq/phc_fids
11 10 8 6 136
root@x64ubuntu8041:~# cat /sys/devices/system/cpu/cpu1/cpufreq/phc_fids
11 10 8 6 136
root@x64ubuntu8041:~#

But I cant set down the processor to 600mHz, to 800mHz only :-(

In the windows I can set the 600mHz (6x100) with rmclock successful, why not in linux?

Can anyone set down a C2D-processor to 600mHz? And if yes, how?

Regards
kasjak2000

I was wondering the same. Apparently the 800 MHz FSB Core 2 Duos on 965 or 45-series chipsets run at 100x8 rather than 100x6 despite the lowest SpeedStep multiplier being 6x. This is the default behavior under Windows and Linux, except I've not seen anybody able to change the multiplier from 8x to 6x in Linux.

skinnie
December 3rd, 2008, 03:21 PM
I tried several time with your module, but it really doesn't work for me. So I compiled it myself and now it works perfect.
I post my file here in case people have trouble or just wanna check.
The module has been compiled for kernel 2.6.27-9 on a 32 bits Intrepid.
Sorry I can't test it now :S I'm back to 64bit...

dirtytofu
December 4th, 2008, 03:04 PM
Need some pointers for a new guy here.

I tried to compile my own acpi_cpufreq module, but after I copied it over it didn't work.

I downloaded the one winnibob uploaded and everything works fine with that module.

I followed all the steps correctly to my belief. The source code I downloaded is "linux-source-2.6.27", but my "uname -r" shows "2.6.27-9-generic". Did I get the right source code to compile off of?

skinnie
December 13th, 2008, 01:35 PM
the "patching" instruction for X64 are different from the ones described in 1st post?
I can't get my phc working...trying it in 2.6.28-2-generic kernel...I assume it is my patching that is not well done...
edit: tried today in ubuntu 8.10 x64 and the same thing happens..
when I do
cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controlIt says it doesn't exist...kernel 2.6.27-10-generic

julakali
December 16th, 2008, 08:25 PM
Precompiled for ubuntu linux-image-2.6.27-10-generic (32bit)
Don't know wether this was necessary or the module compiled for 2.6.27-9 is still working...

homeriq5
December 20th, 2008, 01:47 PM
could someone post the compiled 2.6.27-9 64-bit module as well? That would be quite swell if someone could do that.

XRayA4T
December 20th, 2008, 04:30 PM
Here is the 32-bit version of 2.6.27-11

ivanhoe1024
December 20th, 2008, 05:07 PM
Here's the 64 bit version of the module... give it a try, it works for me... enjoy!!

PS. fixed...:lolflag:

evgeny1978
December 20th, 2008, 08:59 PM
For 64-bit 2.6.27-11

toasty_ghosty
December 20th, 2008, 09:00 PM
About this working on AMD processors....if you built your laptop you can decrease the voltage simply through the bios. I've done this more on one occasion. This might have been answered before but just in case...

Samfisher
December 21st, 2008, 05:49 AM
Here's the 64 bit version of the module... give it a try, it works for me... enjoy!!

hey, the archive gives the error 'not a valid bzip2 archive'! would you be able to upload it again please? thank you!

ivanhoe1024
December 21st, 2008, 06:28 AM
hey, the archive gives the error 'not a valid bzip2 archive'! would you be able to upload it again please? thank you!

I'm sorry, I fixed it...

jcm4
December 21st, 2008, 08:33 PM
cd /home/"your-username"/"kernelversion"
patch -p1 < linux-phc*.patch
make oldconfig
make prepare
make scripts
make M=./arch/x86/kernel/cpu/cpufreq


What am I doing wrong in this? My directory is correct.

john@john-laptop:~/2.6.27-9-generic$ patch -p1 < linux-phc*.patch
can't find file to patch at input line 4
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --new-file -a --unified=5 --recursive linux-source-2.6.26-rc9_orig/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c linux-source-2.6.26-rc9-custom8/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c
|--- linux-source-2.6.26-rc9_orig/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c 2008-07-09 16:59:37.000000000 +0200
|+++ linux-source-2.6.26-rc9-custom8/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c2008-07-09 12:41:37.000000000 +0200
--------------------------
File to patch:

svpersteve
December 26th, 2008, 09:47 PM
With linux kernel 2.6.27-7 in 64-bit Intrepid still gives me an error, and I've been unsuccessful in compiling... I went through all the steps prior to the reboot without any errors, and when I run cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls I get:

cat: /sys/devices/system/cpu/cpu0/cpufreq/phc_controls: No such file or directory

Also, when I enter lsmod | grep acpi_cpufreq
Nothing happens. It just gives another blank prompt, as if I hadn't asked for anything.

But when I restore the backup copy and reboot, I get normal values again.

By the way, I'm using an Lenovo X61T with the latest release of Intrepid (kernel 2.6.27-7).


This is exactly what I get, only I'm not using 64-bit. I'm using an HP dv6000 notebook with Intrepid 8.10 (kernel 2.6.27-9). Can someone please help me out? It gets really hot and my fan is unbelievably noisy!

skinnie
December 27th, 2008, 06:59 AM
This is exactly what I get, only I'm not using 64-bit. I'm using an HP dv6000 notebook with Intrepid 8.10 (kernel 2.6.27-9). Can someone please help me out? It gets really hot and my fan is unbelievably noisy!

Your problem is not only the voltage...
I have a dv9500 and before undervolt and renew of thermal paste,it was like hell,believe or not,now it is cold...and silent :)
End of offtopic :D

pressureman
December 29th, 2008, 08:46 PM
Module for latest Jaunty kernel, 2.6.28-4-generic (32 bit)

zeez
January 2nd, 2009, 11:10 AM
This is exactly what I get, only I'm not using 64-bit. I'm using an HP dv6000 notebook with Intrepid 8.10 (kernel 2.6.27-9). Can someone please help me out? It gets really hot and my fan is unbelievably noisy!


Hello, you need to use the correct kernel...

zeez
January 2nd, 2009, 11:12 AM
Default VIDs: 43 33 26 19
Current VIDs: 0 33 26 19
Testing VID: 0 (700 mV)
..............................
Default VIDs: 43 33 26 19
Current VIDs: -1 33 26 19
Testing VID: -1 (684 mV)
./linux-phc-optimize.bash: line 161: printf: -1: invalid option
printf: usage: printf [-v var] format [arguments]


The lowest acceptable VID is 0.

Recovering CPU.
./linux-phc-optimize.bash: line 138: 22244 Terminated burnMMX


I am getting this error when i execute the script :/

XRayA4T
January 9th, 2009, 06:16 AM
I just upgraded to a new version of the 2.6.27-11 kernel and finally got around to putting together scripts to automate the build and install:

makeACPI:

#!/bin/bash

cd /home/your user name
mkdir `uname -r`
cd `uname -r`
bunzip2 -c /usr/src/linux-source-2.6.27.tar.bz2 | tar xp
cd linux-source-2.6.27/
cp /usr/src/linux-headers-`uname -r`/Module.symvers .
cp /usr/src/linux-headers-`uname -r`/Module.symvers arch/x86/kernel/cpu/cpufreq/
patch -p1 < ../../Downloads/phc/linux-phc-0.3.2-kernel-vanilla-2.6.26.patch
rm ./arch/x86/kernel/cpu/cpufreq/*.symvers
make oldconfig
make prepare
make scripts
make M=./arch/x86/kernel/cpu/cpufreq
cp ./arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.ko ..
cd ..
rm -rf linux-source-2.6.27/


installACPI:

#/bin/bash
cd /lib/modules/`uname -r`/kernel/arch/x86/kernel/cpu/cpufreq/
rmmod speedstep_centrino
rmmod acpi-cpufreq
mv acpi-cpufreq.ko acpi-cpufreq.ko.orig
mv speedstep-centrino.ko speedstep-centrino.ko.orig
cp /home/your user name/`uname -r`/acpi-cpufreq.ko .
modprobe acpi-cpufreq
/etc/init.d/undervolt start


I added the stuff to remove the speedstep-centrino because on my laptop if steedstep-centrino.ko is there it will get loaded instead of acpi-cpufreq and the undervolting does not work.

Run by:
./makeACPI
sudo ./installACPI

Ray

paquito187
January 12th, 2009, 12:56 PM
Here's the 2.6.28.4 generic 64 bit module

pressureman
January 23rd, 2009, 10:52 AM
Module for latest Jaunty kernel, 2.6.28-5-generic (32 bit)

Sacob
January 23rd, 2009, 08:10 PM
my values return to the first ones after i reboot. what can i do to solve this problem?

pressureman
January 24th, 2009, 08:19 PM
my values return to the first ones after i reboot. what can i do to solve this problem?

Add a line like this to your /etc/rc.local (replace my values with your ones).


echo "16:22 14:17 12:12 10:8 8:3 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls


Make sure you add it before the "exit 0" line at the end of rc.local.

Sacob
January 26th, 2009, 07:50 PM
i did the

echo "13:24 10:1 8:1 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls

and the result of the

cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls

is indeed "13:24 10:1 8:1 6:1". the problem is that after i reboot this values return to the first ones


ps: sorry for my bad english

seish
January 27th, 2009, 02:40 PM
Here's the 2.6.28.4 generic 64 bit module


EDIT: Nvm just googled and found the new kernel for ubuntu.

seish
January 27th, 2009, 09:26 PM
How can I find/compile a module for kernel 2.6.28 64 bit ?

The precompiled module for 64 bit posted on page 30 doesn't work. Also the links in the guide are broken and the guide is kinda outdated to be useful now. Not to mention I can't find the linux PHC website anywhere.
Either I'm really clueless or noone cares about undervolting anymore.

I want to use the new kernel, but I can't unless I get this working.

Ev1L
January 28th, 2009, 02:18 PM
i did the

echo "13:24 10:1 8:1 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls

and the result of the



is indeed "13:24 10:1 8:1 6:1". the problem is that after i reboot this values return to the first ones


ps: sorry for my bad english
did you just wrote that command in the console or actually put it in rc.local?
the second is supposed to be permanent, and i couldn't figure out why it would be reset at reboot

marcelorider
January 28th, 2009, 04:22 PM
easy way to undervolt a speedstep centrino is

opening blacklist list and add blacklist speedstep_centrino (if im not wrong)

then simply replace the acpi kernel for the modified :P
and put boot command or what u guys whant :P

the 32bits patch for kernel 2.6.27.11-generic on page 29 works like sharm :)

good undervolting :)

original topic need update for new kernels

ohh i forgot its the 3th time i undervolt my laptop sucessfully with this topic

pressureman
January 28th, 2009, 08:20 PM
did you just wrote that command in the console or actually put it in rc.local?
the second is supposed to be permanent, and i couldn't figure out why it would be reset at reboot

I wrote that you should add the line to /etc/rc.local (since that gets executed upon booting). Also, you should replace my values with the ones that the script determined for your CPU. It's unlikely that your values will be the same as mine, unless we have identical CPUs.

Sacob
January 28th, 2009, 10:23 PM
did you just wrote that command in the console or actually put it in rc.local?
the second is supposed to be permanent, and i couldn't figure out why it would be reset at reboot

i only wrote this line in the console, as it was in the tutorial

didn't understand the rc.local thing

Ev1L
January 29th, 2009, 05:36 AM
I wrote that you should add the line to /etc/rc.local (since that gets executed upon booting). Also, you should replace my values with the ones that the script determined for your CPU. It's unlikely that your values will be the same as mine, unless we have identical CPUs.
I am not the one asking for help, I was not sure Sacob understood your point on adding to rc.local.

Now I guess he did :)

pressureman
January 29th, 2009, 06:18 AM
I am not the one asking for help, I was not sure Sacob understood your point on adding to rc.local.

Now I guess he did :)

Ooops... sorry #-o

Must be the sleep deprivation and constant travelling.

pressureman
January 29th, 2009, 06:22 AM
Module for latest Jaunty kernel, 2.6.28-6-generic (32 bit)

m4cph1sto
January 30th, 2009, 12:34 AM
I have a speedstep-centrino Pentium M. Interestingly, when I switch to the PHC- modded acpi-cpufreq, and undervolt, my CPU temp actually increases, and consumes MORE power. So I have a request:

Can anyone compile a PHC modded speedstep-centrino.ko for Ubunto kernel 2.6.27-11-generic? I've tried myself but couldn't quite get it to work, and now it seems the Linux-PHC website is down. So if someone has downloaded the patch for speedstep-centrino that was posted on Linux-PHC - it is also posted and still available here:

http://ubuntuforums.org/showthread.php?t=970662

and can spend a few minutes to compile the module for this most recent kernel, I would greatly appreciate it!

Ev1L
January 30th, 2009, 04:30 AM
I have a speedstep-centrino Pentium M. Interestingly, when I switch to the PHC- modded acpi-cpufreq, and undervolt, my CPU temp actually increases, and consumes MORE power. So I have a request:

Can anyone compile a PHC modded speedstep-centrino.ko for Ubunto kernel 2.6.27-11-generic? I've tried myself but couldn't quite get it to work, and now it seems the Linux-PHC website is down. So if someone has downloaded the patch for speedstep-centrino that was posted on Linux-PHC - it is also posted and still available here:

http://ubuntuforums.org/showthread.php?t=970662

and can spend a few minutes to compile the module for this most recent kernel, I would greatly appreciate it!
have you tried the couple already compiled that are present in this thread?
by the way i experienced a little increase in temp too, but i suspect that it was cause i was doing almost nothing when i was without PHC

m4cph1sto
February 1st, 2009, 03:45 PM
I can't find any patched speedstep-centrino.ko posted in this thread. Compiling my own results in a fully functioning speedstep-centrino module, but generates no phc files in /sys/devices/system/cpu/cpu0/cpufreq/, so the undervolting part isn't working. Switching to acpi-cpufreq and following the method in the first post of this thread seems to work fine, however I'm not seeing any temperature decrease or power saving with acpi-cpufreq and undervolting (in fact if anything it's worse), which is why I wanted to try patching speedstep-centrino instead.

Maybe I'm just asking too much, since speedstep-centrino is only for older hardware, it doesn't make sense to devote much time in getting this to work. But it would sure be nice for people with older laptops, like me :)

pressureman
February 9th, 2009, 05:38 PM
Module for latest Jaunty kernel, 2.6.28-7-generic (32 bit)

wubi-user
February 14th, 2009, 02:03 AM
easy way to undervolt a speedstep centrino is

opening blacklist list and add blacklist speedstep_centrino (if im not wrong)

then simply replace the acpi kernel for the modified :P
and put boot command or what u guys whant :P

the 32bits patch for kernel 2.6.27.11-generic on page 29 works like sharm :)

good undervolting :)

original topic need update for new kernels

ohh i forgot its the 3th time i undervolt my laptop sucessfully with this topic

that's great to know, marcelorider. I'm a complete novice with linux, but i'm ready to make the switch from windows if I could get the undervolting done. But this is by far the hardest thing I've come across so I would love to get all the help i can. My notebook has a Pentium M 740 and I know that it is currently running speedstep_centrino. My kernel is 2.6.27.11 and I know there are tutorials around that teach my how to do it, BUT this whole blacklisting business isn't covered. Any advice is welcomed. Thanks.

Mizzou_Engineer
February 14th, 2009, 11:37 AM
that's great to know, marcelorider. I'm a complete novice with linux, but i'm ready to make the switch from windows if I could get the undervolting done. But this is by far the hardest thing I've come across so I would love to get all the help i can. My notebook has a Pentium M 740 and I know that it is currently running speedstep_centrino. My kernel is 2.6.27.11 and I know there are tutorials around that teach my how to do it, BUT this whole blacklisting business isn't covered. Any advice is welcomed. Thanks.

Here's how to blacklist a module:

1. Hit Alt-F2 to bring up the "Run Application" dialog.

2. Type in "gksudo gedit" (less quotes) to run GEdit as root.

3. Open /etc/modprobe.d/blacklist with GEdit.

4. Scroll down to the end of the list.

5. Type in "blacklist speedstep_centrino" (less quotes) to blacklist speedstep_centrino.

6. Save and close GEdit.

That should do it.

Note: If you are a CLI guy like I am, just open /etc/modprobe.d/blacklist as root with your favorite text editor and add "blacklist speedstep_centrino" at the end.

primus454
February 14th, 2009, 05:17 PM
Okay, I finished step two and rebooted. Everything came up fine, but I lost my internet. I reinstalled my / drive because I can't live without internet. Any insight as to why that happened and how to fix it? I'm running Intrepid 64 on a 64bit machine. I'm running 2.6.27-11-generic.

vasiauvi
February 15th, 2009, 05:35 AM
Hello all,
I have read almost all this thread and I've tried to run the scripts.
As I understood from the first page after installing PHC controls with this command :
cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls I can see the default values. Then, my default values appeared to be:
14:1 12:36 10:32 8:28 6:25
First 14:1 means that by default my CPU is set on the lowest voltage???
After running the script in parallel with burnMMX this is the output:

Default VIDs: 40 36 32 28 25
Current VIDs: 39 36 32 28 25
Testing VID: 39 (1324 mV)
..........
Default VIDs: 40 36 32 28 25
Current VIDs: -1 36 32 28 25
Testing VID: -1 (684 mV)
./linux-phc-optimize.bash: line 161: printf: -1: invalid option
printf: usage: printf [-v var] format [arguments]


The lowest acceptable VID is 0.

Recovering CPU.
./linux-phc-optimize.bash: line 138: 10115 Terminated burnMMX

Run this script again to continue the optimization.
paula@paula:~/Documents$ sudo ./linux-phc-optimize.bash

I assume you have linux-phc correctly installed and working.
This script will optimize your voltages at every speed setting by
systematically lowering them while stressing the CPU.
Each voltage will be turned down until your system crashes, and the final
setting for that voltage will be 2 VIDs above that to "ensure" stability.

WARNING:
This script will crash your system as many times as there are VIDs to tweak.
You might destroy your hardware, break laws and/or die in vain if you continue.

Do you want to continue? [Y/n/?] Yes

Install required packages.
Will use burnMMX (part of cpuburn package) to stress CPU.
Install: cpuburn
> SKIPPED: Already installed


Will use current directory to store/retrieve test results.

Read phc_default_vids:
> Success!

Load VIDs from 'phc_tweaked_vids'
> ERROR: Wrong VID count!

I don't understand what is wrong or if it's something wrong.
My CPU temp is between 52 and 62 degrees C.
I am missing something???
Thank you in advance!!!

vasiauvi
February 15th, 2009, 02:55 PM
OK, today i have tried all the possibilities but i think that the undervoltage doesn't work.Now i've put 14:25 12:25 10:25 8:25 6:25 and the temperature is the same.I have installed PHCtool i have used the script but nothing.I have Intel Duo T2130 on ASUS laptop.
In /etc/rc.local i've put:

echo "14:1 12:19 10:19 8:19 6:19" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
echo "14:1 12:19 10:19 8:19 6:19" > /sys/devices/system/cpu/cpu1/cpufreq/phc_controls

When i run the script the laptop doesn't hung up or freeze.
I've give up, time spend for nothing!!:(:confused:

Although this forum and the community is GREAT!!!!

mister_playboy
February 17th, 2009, 11:46 AM
cd /home/"your-username"/"kernelversion"
patch -p1 < linux-phc*.patch
make oldconfig
make prepare
make scripts
make M=./arch/x86/kernel/cpu/cpufreq


What am I doing wrong in this? My directory is correct.

john@john-laptop:~/2.6.27-9-generic$ patch -p1 < linux-phc*.patch
can't find file to patch at input line 4
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --new-file -a --unified=5 --recursive linux-source-2.6.26-rc9_orig/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c linux-source-2.6.26-rc9-custom8/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c
|--- linux-source-2.6.26-rc9_orig/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c 2008-07-09 16:59:37.000000000 +0200
|+++ linux-source-2.6.26-rc9-custom8/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c2008-07-09 12:41:37.000000000 +0200
--------------------------
File to patch:

I'm getting the exact same problem... trying to compile for 2.6.28-8 64bit kernel.

Thanks to this thread, I had undervolting working perfectly with 2.6.27-11, but I'm trying out the new kernel to improve my folding@home SMP performance.

mister_playboy
February 17th, 2009, 01:29 PM
Nevermind, digging through the whole thread solved my problem.

I was having trouble since I hadn't downloaded the linux-headers package for my new kernel.

Thanks for all the guidance! :) Here is the fruit of my labors:

pressureman
February 17th, 2009, 02:59 PM
Module for latest Jaunty kernel, 2.6.28-8-generic (32 bit)

nigelhealy
February 17th, 2009, 11:38 PM
So I spent hours on this. I have Ubuntu 8.10 AMD64 o a Thinkpad T60. I was looking at undervolting to reduce heat and therefore the fan and therefore quieter and some hope of better battery. This having used laptop_mode and powertop tips.

On wifi, screen on a low brightness, am getting about 3.5 hours, down from 2 hours before I tried all the tweaks going.

This underclocking guide the scripts simply would not work. The pre-compiled modules and the instructions to replace existing did work, but I had to use the phctool to manually trial+error find the lowest reliable VID for each of my 5 clock frequency.

I would like to get over 4 hours of battery. I notice the laptop spends about 98% of its time in the lowest clock.

XRayA4T
February 18th, 2009, 02:54 AM
Here is Intrepid 2.6.27-12 32-bit

pressureman
February 19th, 2009, 09:58 AM
Patching the acpi-cpufreq module just got a little bit harder in Jaunty. As of 2.6.28-8.24, the CPU frequency scaling modules are built in to the kernel, meaning that we can no longer just patch and overwrite an individual module.

Mizzou_Engineer
February 19th, 2009, 10:39 AM
Patching the acpi-cpufreq module just got a little bit harder in Jaunty. As of 2.6.28-8.24, the CPU frequency scaling modules are built in to the kernel, meaning that we can no longer just patch and overwrite an individual module.

It's not that big of a deal to change, though. The kernel source patching procedure is the same, although you will need to recompile the entire kernel and move the kernel bzImage to /boot rather than compiling the acpi_cpufreq.ko module and moving it to /lib/modules/. It's not that much more difficult and given that the acpi_cpufreq driver only supports newer CPUs, compile time ought not to be all that ridiculous either.

gmc
February 19th, 2009, 10:40 AM
Aww now that just sucks. Well I guess I'll just have to get off my lazy butt and start custom compiling my own kernel for my AAO-150.

I wonder why the change from module to internal, or if it was just an oversight.

G.

pressureman
February 19th, 2009, 11:02 AM
I've been running the unpatched kernel for a few hours now, and I can't honestly say I've noticed any difference. This is a pretty old laptop, and the battery is completely shot anyway, so it only gets about 25 mins runtime. For me, patching the module was never about increasing battery runtime.

As far as temperature however, it's about the same, and the fan pretty much always ran non-stop anyway. I think the graphics chipset is reponsible for most of the heat (ATI Radeon Mobility 9700).

This really just hastens my decision to get a new laptop with better cooling.

Ev1L
February 19th, 2009, 11:15 AM
It's not that big of a deal to change, though. The kernel source patching procedure is the same, although you will need to recompile the entire kernel and move the kernel bzImage to /boot rather than compiling the acpi_cpufreq.ko module and moving it to /lib/modules/. It's not that much more difficult and given that the acpi_cpufreq driver only supports newer CPUs, compile time ought not to be all that ridiculous either.
Well, I cannot say that download and recompile the kernel everytime is anything comparable to get the update automatically from update manager, grab the library from here, and replace the old one.

There is always someone here recompiling the new module and sharing it, now it's pointless, and everyone has to do the long and annoying procedure himself.

I'd like to know the reason of this change, and I hope there will be a more comfortable workaround.
Actually, I was also wondering why kernels and phc don't come together.

Mizzou_Engineer
February 19th, 2009, 01:59 PM
Well, I cannot say that download and recompile the kernel everytime is anything comparable to get the update automatically from update manager, grab the library from here, and replace the old one.

There is always someone here recompiling the new module and sharing it, now it's pointless, and everyone has to do the long and annoying procedure himself.

I'd like to know the reason of this change, and I hope there will be a more comfortable workaround.
Actually, I was also wondering why kernels and phc don't come together.

I was always compiling my own modules, since I was also trying to use the Broadcom wl driver as well (which required a very similar procedure.) Maybe somebody could write a script that would do the necessary actions all in one shot...

evgeny1978
February 20th, 2009, 09:41 PM
64 bit acpi-cpufreq.ko for 2.6.27-12-generic

gmc
February 22nd, 2009, 04:32 AM
Not having a whole lot of luck here. I've downloaded and applied linux-phc-0.3.2-kernel-vanilla-2.6.26.patch to the current Jaunty kernel (2.6.28-8-generic #24).

Applying the patch didn't report any error's but I'm not able to get the module to compile. but get the following:


:~/src/linux-source-2.6.28$ make M=./arch/x86/kernel/cpu/cpufreq

WARNING: Symbol version dump /home/gord/src/linux-source-2.6.28/Module.symvers
is missing; modules will have no dependencies and modversions.

LD arch/x86/kernel/cpu/cpufreq/built-in.o
ld: no input files
make[1]: *** [arch/x86/kernel/cpu/cpufreq/built-in.o] Error 1
make: *** [_module_./arch/x86/kernel/cpu/cpufreq] Error 2
Am I missing something somewhere?

G.

Mizzou_Engineer
February 22nd, 2009, 11:13 AM
Not having a whole lot of luck here. I've downloaded and applied linux-phc-0.3.2-kernel-vanilla-2.6.26.patch to the current Jaunty kernel (2.6.28-8-generic #24).

Applying the patch didn't report any error's but I'm not able to get the module to compile. but get the following:


:~/src/linux-source-2.6.28$ make M=./arch/x86/kernel/cpu/cpufreq

WARNING: Symbol version dump /home/gord/src/linux-source-2.6.28/Module.symvers
is missing; modules will have no dependencies and modversions.

LD arch/x86/kernel/cpu/cpufreq/built-in.o
ld: no input files
make[1]: *** [arch/x86/kernel/cpu/cpufreq/built-in.o] Error 1
make: *** [_module_./arch/x86/kernel/cpu/cpufreq] Error 2
Am I missing something somewhere?

G.

Look at message #323 in this thread- the module is compiled into the kernel and unable to be patched. Plus, you need to grab Module.symvers out of the kernel headers folder and put it in the linux-source folder, else you won't be able to insert any module you would have compilied.

mister_playboy
February 22nd, 2009, 11:45 AM
Plus, you need to grab Module.symvers out of the kernel headers folder and put it in the linux-source folder, else you won't be able to insert any module you would have compilied.

That was the problem I had originally, but in my haste I forgot to post the fix (which is very simple). :)

Dark_vampel
February 23rd, 2009, 01:32 PM
I'm having problems after copying the module into the kernel. I copied the correct module for the 2.6.24-19-generic. I reboot then try to run the cat command but then I get an error saying the device does not exist. Where could I have made a mistake or is my processor not supported? It is a pentinium 4.

matmat07
February 24th, 2009, 04:04 PM
Could someone make me a 64 bit 2.6.27-9 one? I tried but something went wrong and I had to reinstall the kernel.

matmat07
February 26th, 2009, 11:09 PM
nvm, I found one while searching in this thread

Yink
March 3rd, 2009, 05:05 PM
I hate to sound ignorant but does this mean for 2.6.27-13-generic I will need to download the kernel source and apply a patch to it, or is the module been moved inside the kernel on the next Ubuntu version ?

Sorry if my question is n00bish.

zcats
March 4th, 2009, 07:51 AM
Thanks. Undervolting has been a fantastic for reducing temperature and fan noise....
Can someone please post 32 bit for 2.6.27-13?:P

Would be really useful if all these .ko files could be tabulated or a sticky made with links to all the downloads...takes ages looking for the right .ko for the kernel.
Will try the 2.6.27-12.ko and see if it works with 2.6.27-13 in the meantime (guess I will have to learn to compile my own one day soon!)

Thanks
zcats

alkis
March 10th, 2009, 07:55 AM
Intrepid 2.6.27-13 64 bit

XRayA4T
March 11th, 2009, 06:04 AM
Here is Hardy 2.6.27-13-generic-32bit

Yink
March 11th, 2009, 03:33 PM
Thanks a lot!

zcats
March 14th, 2009, 03:25 PM
Thanks! The 2.6.27-13-generic 32 bit worked fine for me.

NB
In the instructions (1st page) for ubuntu you do need to run
>sudo -s
before you change the voltages with
>echo "17:15 14:9 12:28 10:5 8:1 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls

Also, I have T42 Thinkpad laptop with 2 gig RAM.This was a bit wierd...
17:36 14:32 12:28 10:25 8:22 6:18 original vids
17:15 14:9 12:5 10:1 8:1 6:1 optimal as tested after sudo ./linux-phc-optimize.bash.
But thinkwiki recommends
17:19 14:12 12:8 10:4 8:1 6:1

......but in the end I settled for 17:15 14:9 12:28 10:5 8:1 6:1 because I had some stability issues. This is one of the best tweaks for cooling laptop and the fan running at high speed often. My laptop used to be a gasping beast with the fan belting a lot of the time and the cpu temps going abobe 80 celcius (yikes! but the Pentium M can take more than 100 celcius..amazing but I do not like it). After this undervolt, I can max out this laptop, its stable and temps are usually less than 60 celsius with the fan off or at 10%. Cool Thinkpad fan control was also useful, but the undervolting sorted out the excessive heat production and made it just cool:P

When will this get into the kernel? no danger of UNDERvolting right? So lets have it inbuilt into the vanilla please

shadeslayer
March 14th, 2009, 04:37 PM
hey guys,amazing guide...... but after a reboot the values return to the default one's.
Mine are : 75:40 74:34 8:28 6:23 136:15 <--after Reboot
75:31 74:34 8:28 6:23 136:15 <--before running scripts
75:36 74:34 8:1 6:1 136:1 <--what the script gives me

I have a T8100 on my XPS M1530,and the thing runs wayyyy to hot to sit on my lap.A urgent fix required please!!! :)
Thanks in advance

Kernel : 2.6.27-13 64 bit

Mizzou_Engineer
March 14th, 2009, 11:18 PM
hey guys,amazing guide...... but after a reboot the values return to the default one's.
Mine are : 75:40 74:34 8:28 6:23 136:15 <--after Reboot
75:31 74:34 8:28 6:23 136:15 <--before running scripts
75:36 74:34 8:1 6:1 136:1 <--what the script gives me

I have a T8100 on my XPS M1530,and the thing runs wayyyy to hot to sit on my lap.A urgent fix required please!!! :)
Thanks in advance

Kernel : 2.6.27-13 64 bit

The phc_controls get reset to default when the computer reboots. I just set up a script that echoes the desired undervolting values and run it after reboot.

shadeslayer
March 15th, 2009, 07:00 AM
The phc_controls get reset to default when the computer reboots. I just set up a script that echoes the desired undervolting values and run it after reboot.

So that means that either i set up my own script or i echo the values each time i login? That well kinda sucks if you are a average user and have just started to use ubuntu.Cant i have something that starts up automatically on boot(during the load period) to echo the new values??

Mizzou_Engineer
March 15th, 2009, 11:05 PM
So that means that either i set up my own script or i echo the values each time i login? That well kinda sucks if you are a average user and have just started to use ubuntu.Cant i have something that starts up automatically on boot(during the load period) to echo the new values??

Yes, you can. Put the (executable) script in /etc/rc.d and then do a "sudo /usr/sbin/update-rc.d $SCRIPT_NAME defaults" to have it set the PHC controls at boot.

If you need a hand in doing this, just say so.

shadeslayer
March 16th, 2009, 08:47 AM
Yes, you can. Put the (executable) script in /etc/rc.d and then do a "sudo /usr/sbin/update-rc.d $SCRIPT_NAME defaults" to have it set the PHC controls at boot.

If you need a hand in doing this, just say so.

yep,ill need all the help i can :D ,could you possibly post step by step instructions and the script i would need??

zcats
March 17th, 2009, 02:20 PM
Changes will be lost on reboot unlees you add YOUR values to your /etc/rc.local file to make permanent (no script needed just add few lines to /etc/rc.local so it looks like that below (replace vids with your optimal values). Values stay after new kernel upgrade (PHC patched)...
>sudo gedit /etc/rc.local

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
echo "17:19 14:12 12:18 10:4 8:1 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
exit 0

http://ubuntuforums.org/showthread.php?t=786402&highlight=phc

XRayA4T
March 23rd, 2009, 06:35 AM
It appears that with Jaunty the ACPI stuff is now in the kernel rather than in a module which requires you to patch and build the kernel. Having never done this before I decided to take the plunge and give it a go! I followed the instructions here http://beginlinux.wordpress.com/2008/12/03/how-to-compile-an-ubuntu-810-kernel/ and it was pretty straight forward if time consuming.

I have created a script to simplify the process. Create a folder where you have write access. Put the following script in that folder, buildKernel:

#!/bin/sh
if [ "$1" = "" ]; then
echo "Usage: $N {version number}" >&2;
exit 1;
fi
start=`date`
echo "Started : $start"
bunzip2 -c /usr/src/linux-source-2.6.28.tar.bz2 | tar xp
cd linux-source-2.6.28
cp /boot/config-`uname -r` ./.config
patch -p1 < ../linux-phc-0.3.2-kernel-vanilla-2.6.26.patch
make-kpkg clean
fakeroot make-kpkg --initrd --append-to-version=-rb${1} kernel_image kernel_headers
cd ..
rm -rf linux-source-2.6.28
echo "Started : $start"
echo "Ended : `date`"

You can replace the rb in --append-to-version=-rb${1} with your initials. You can then make it executable and run it as "buildKernel 2" where 2 is the version number you want to assign.

It takes up about 4GB during the build process (which the last line in the script deletes) to build the 2 deb packages which are about 300MB. The build took about 2 hours on my machine. You can then install the 2 packages and use the undervolting as you did when it was a module.

Hope this helps
Ray

Ev1L
March 23rd, 2009, 06:54 AM
I am not expert enough, so I ask again.
Are you sure that for something so useful as phc there isn't a way to install it seamlessly like any package from apt?

could someone quickly explain me a bit the logic before the new kernel and the current one?
and maybe also why change something requiring everyone to recompile a kernel instead of just a module?

thanks

Ares Drake
March 24th, 2009, 11:00 AM
I am not expert enough, so I ask again.
Are you sure that for something so useful as phc there isn't a way to install it seamlessly like any package from apt?

could someone quickly explain me a bit the logic before the new kernel and the current one?
and maybe also why change something requiring everyone to recompile a kernel instead of just a module?

thanks


Well in theory you could compile your own phc-enabled kernel into a *.deb and distribute it via apt, i guess. Unfortunately I am a) no kernel expert and b) still using Hardy, so I am probably of little help in that matter for now.

Ev1L
March 24th, 2009, 11:08 AM
well, i read the discussion on phc forum, i hope they'll come up with a nice, clean and easy solution.
i could really stop using phc if i should recompile the kernel everytime, i kinda like ubuntu telling me that there is a new kernel and installing it for me :)
quickly reinstall phc, asus stuff, virtual box and vmware was still acceptable, but the whole kernel...

i hope not :)

juanmoreno92
March 29th, 2009, 04:32 AM
Any word on support for dual cores yet? My Pentium Dual Core Toshiba Satellite can cook a T-bone in about 2 min. right now.

kabaiz
March 31st, 2009, 02:53 AM
Thanks for the great script! I hope it will work for me, too.

Before compiling I have some questions:

Is that a 32 or 64 bit system? Can you tell us the properties of your processor?

Is there a difference between patching a 32 bit or a 64 bit kernel?

Have a nice day :)

Zoltan

Supermattt
April 1st, 2009, 10:44 AM
Am I totally Crazy or the acpi_cpufreq is hardcoded in last jaunty 2.6.28-11 kernel? :confused:

matt@merom:~ $ uname -r
2.6.28-11-generic
matt@merom:/lib/modules/2.6.28-11-generic/kernel/arch/x86/kernel/cpu/cpufreq $ ls
e_powersaver.ko p4-clockmod.ko


root@merom:~ # lsmod |grep acpi
root@merom:~ # lsmod |grep cpu
root@merom:~ #

pressureman
April 1st, 2009, 07:22 PM
It's compiled in now. This was discussed earlier in this rather epic thread.

pressureman@thinkpad:~$ egrep "CPUFREQ|POWERNOW|SPEEDSTEP" /boot/config-2.6.28-11-generic
CONFIG_X86_ACPI_CPUFREQ=y
# CONFIG_X86_ACPI_CPUFREQ_PROC_INTF is not set
CONFIG_X86_CPUFREQ_NFORCE2=y
CONFIG_X86_POWERNOW_K6=y
CONFIG_X86_POWERNOW_K7=y
CONFIG_X86_POWERNOW_K7_ACPI=y
CONFIG_X86_POWERNOW_K8=y
CONFIG_X86_POWERNOW_K8_ACPI=y
CONFIG_X86_SPEEDSTEP_CENTRINO=y
CONFIG_X86_SPEEDSTEP_CENTRINO_TABLE=y
CONFIG_X86_SPEEDSTEP_ICH=y
CONFIG_X86_SPEEDSTEP_LIB=y
CONFIG_X86_SPEEDSTEP_RELAXED_CAP_CHECK=y
CONFIG_X86_SPEEDSTEP_SMI=y

Supermattt
April 4th, 2009, 05:32 AM
I created a thread about the hard-coded thing in idea's box, hope someone will read it !

If you want to add comments ->
http://ubuntuforums.org/showthread.php?p=7010930#post7010930

nick_edwards
April 9th, 2009, 07:40 PM
I'm loosing my mind,
I've followerd this guide before and it worked great but now upgraded kernel and I need to compile the module again, I remember I had trouble last time with this same step but ca't remember what I did:

basically I can't copy /boot/config-$(uname -r).config to /home/"your-username"/"kernelversion" as I don't have that file???????

root@amd64:/boot# ls /boot/config-$(uname -r).config
ls: cannot access /boot/config-2.6.27-14-generic.config: No such file or directory


even though:

root@amd64:/boot# apt-get install build-essential linux-source
Reading package lists... Done
Building dependency tree
Reading state information... Done
build-essential is already the newest version.
linux-source is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.


WTF???? am I being a retard here or has something changed??

nick_edwards
April 10th, 2009, 12:31 AM
ok ignore my last post, I followed the how to on the PHP website and got it compiled and installed..

now....

I don't think it's working...

running 2 x burnMMX on my dell M1330 gets the temperature well over 90 degrees in very little time. :oops:

cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
13:25 12:15 10:1 8:1 6:1 136:1


which is the same values I used to use and they used to work very well temperature wouldn't rise much over 70 with the same test.

I'm using x86 ubuntu 8.10 with the 2.6.27-14-generic kernel - anyone had any luck with it? want to post me your compiled module?? anyone want my compiled module?

any help is greatly appreciated, these things tend to screw with my sanity far more than they should.](*,)

Sianis
April 11th, 2009, 05:02 AM
Hello!

I'm running Intrepid Ibex with 2.6.27-11-generic on a T61 with T8300 Core 2 Duo.

I run the script with two burnMMX.

The script (after 6 system crash) give me this:


cat phc_tweaked_vids
23 23 1 1 1 1


My default phc_control file is:

cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
13:40 12:34 10:31 8:27 6:23 136:17


So my new phc_control file should be:

13:23 12:23 10:1 8:1 6:1 136:1


But this version crash my system randomly. What is the problem?
Thanks for your help!

Ev1L
April 11th, 2009, 07:32 AM
maybe it was too undervolted for some reason.
you could try the test again maybe

Pluies
April 11th, 2009, 12:28 PM
About the following error while running linux-phc-optimize.bash :


(...)
Default VIDs: 34 28 21 15
Current VIDs: 1 28 21 15
Testing VID: 1 (716 mV)
..............................
Default VIDs: 34 28 21 15
Current VIDs: 0 28 21 15
Testing VID: 0 (700 mV)
..............................
Default VIDs: 34 28 21 15
Current VIDs: -1 28 21 15
Testing VID: -1 (684 mV)
./linux-phc-optimize.bash: line 161: printf: -1: invalid option
printf: usage: printf [-v var] format [arguments]


The lowest acceptable VID is 0.

Recovering CPU.
pkill: 11249 - Operation not permitted
./linux-phc-optimize.bash: line 138: 9516 Terminated burnMMX

Run this script again to continue the optimization.
pluies@pluies-laptop ~/phctools $ ./linux-phc-optimize.bash

I assume you have linux-phc correctly installed and working.
This script will optimize your voltages at every speed setting by
systematically lowering them while stressing the CPU.
Each voltage will be turned down until your system crashes, and the final
setting for that voltage will be 2 VIDs above that to "ensure" stability.

WARNING:
This script will crash your system as many times as there are VIDs to tweak.
You might destroy your hardware, break laws and/or die in vain if you continue.

Do you want to continue? [Y/n/?] Yes

Install required packages.
Will use burnMMX (part of cpuburn package) to stress CPU.
Install: cpuburn
> SKIPPED: Already installed


Will use current directory to store/retrieve test results.

Read phc_default_vids:
> Success!

Load VIDs from 'phc_tweaked_vids'
> ERROR: Wrong VID count!



It seems like there's a bug when your processor is too good and can run without crashing at a very low vid (typically, at a VID of 0).

One workaround is to modify line 161 of the linux-phc-optimize.bash script.
Replace:
while [[ 1 ]]; do
By:
while [[ vid[cur_pos] -ge 1 ]]; do

It will prevent the tool from trying to set VIDs lower than 1.

You will then have to delete phc_cur_pos and phc_tweaked_vids (the two files where the bash script saves its VIDs); then relaunch the script... Ta-dam. Worked perfectly fine here. :)

Sianis
April 11th, 2009, 01:25 PM
Ok. So I created an other test. Results are same. BUT. My system crashes when it want to change the cpu scale, frequency. It is stable on the fixed frequency, but changing crashes it. Have you ever this problem. What could this be?

Thank you!

Pluies
April 11th, 2009, 03:21 PM
Ok. So I created an other test. Results are same. BUT. My system crashes when it want to change the cpu scale, frequency. It is stable on the fixed frequency, but changing crashes it. Have you ever this problem. What could this be?

Thank you!

I don't know about you, but on my install, phc-intel doesn't seem to actually modify the VIDs. It may explain why the processor is able to run this low during the script without any problem.

I think the best solution so far is to set voltage manually (using PHCTools). Not very practical, but it should work better.



Edit: hehe. I just understood my problem.

My default VIDs are (in /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids ):
pluies@pluies-laptop ~/Desktop $ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
34 28 21 15

My available frequencies are:
pluies@pluies-laptop ~/Desktop $ cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
1600000 1400000 1200000 800000


So, when I try to set a VID lower than 15... PHC will never reach it; and will stop at 15, which is the default lowest VID of my lowest frequency (in my case, 800Mhz). Let's call it "EXTRAMINVID".

My tests so far showed that you can't set a VID inferior to this value. For each frequency, every value between your default value for this frequency and EXTRAMINVID are possible though. :)


I just set all my voltages at 15 using PHCTools. Now, for every frequency, VID is always 15. Even at max frequency (1,6Ghz).

I'm letting burnMMX run a bit to see if it is stable and let you know.

Mizzou_Engineer
April 11th, 2009, 10:41 PM
My tests so far showed that you can't set a VID inferior to this value. For each frequency, every value between your default value for this frequency and EXTRAMINVID are possible though. :)


That is correct. Intel does not let you set a voltage lower than the default voltage at the lowest frequency for your particular CPU. This voltage will lie between the upper and lower boundaries of Vcc_LFM (Intel chips on 945 and older chipsets) or Vcc_SLFM (Intel chips on 965 and newer chipsets) and can be different for each individual CPU. But whatever this lowest VID is, you cannot set any VID for any frequency below this value. This is also true for AMD desktop chips- you cannot set the voltage lower than the voltage when the chip is at its idle speed (which generally is 0.9-1.1 volts, depending on model.)

AMD laptop chips are a different story. You can lower the VIDs on those guys well below the pre-defined idle VID for any FID, as long as the CPU remains stable. I think my wife's Mobile Sempron 3600+ that normally idles at about 950 mV has VIDs unlocked to something like 0.5625 volts or something crazy like that.

mister_playboy
April 24th, 2009, 04:27 AM
It appears that 19 is the lowest acceptable setting for many Intel Core 2 Duos and Pentium Dual-cores. I was having the same problem with the script going to 0 or -1. I just set 19's across the board and every thing is fine.

If you have one of these chips, give this setting a try.

ivanhoe1024
April 24th, 2009, 03:26 PM
Ehi guys, I've got a big problem with jaunty... I read that I have to recompile the whole kernel, and I did it, with no errors, but... I have not enough free disk space!! In the root partition I've got about 5 gb free, but when the pc create the kernel image, it is full... I reached now 6,2 gb free, are they enough? How can I do?? Any Ideas?? ps. sorry for my english, I'm italian :P
I've got another partition, bigger that that, which I use for the Home directory, but I think I can't use that free space, can I??

If someone posts online the kernel-image and the kernel-headers packages with the mod indicated in the original phc site, everybody who use the default kernel and the phc patch could download and use it... Is there someone who wants to became a hero???

evgeny1978
April 27th, 2009, 10:05 PM
You can download recompiled kernel 64-bit version for jaunty with "ACPI Processor P-States driver" as a module at ftp://129.93.36.1/linux-headers-2.6.28.9-phc001_2.6.28.9-phc001-10.00.Custom_amd64.deb and ftp://129.93.36.1/linux-image-2.6.28.9-phc001_2.6.28.9-phc001-10.00.Custom_amd64.deb (I followed instructions at http://www.linux-phc.org/forum/viewtopic.php?f=13&t=67 and http://www.linux-phc.org/forum/viewtopic.php?f=13&t=2 for phc-intel-0.3.2-4.tar.gz file. By the way this is actually 2.6.28.11 kernel). This kernel files will be available for downloading for several days only (week maximum).

ivanhoe1024
April 28th, 2009, 06:47 AM
You can download recompiled kernel 64-bit version for jaunty with "ACPI Processor P-States driver" as a module at ftp://129.93.36.1/linux-headers-2.6.28.9-phc001_2.6.28.9-phc001-10.00.Custom_amd64.deb and ftp://129.93.36.1/linux-image-2.6.28.9-phc001_2.6.28.9-phc001-10.00.Custom_amd64.deb (I followed instructions at http://www.linux-phc.org/forum/viewtopic.php?f=13&t=67 and http://www.linux-phc.org/forum/viewtopic.php?f=13&t=2 for phc-intel-0.3.2-4.tar.gz file. By the way this is actually 2.6.28.11 kernel). This kernel files will be available for downloading for several days only (week maximum).

Wow, you're my hero!! Ok, I'm downloading them... Just a question: after I downloaded them, Do I have to patch them looking at http://www.linux-phc.org/forum/viewtopic.php?f=13&t=2, or are they just patched??
Thanks a lot!!

PS. I installed your two packages, but I have this error. Does anyone know what does it mean??

Examining /etc/kernel/postinst.d.
run-parts: executing /etc/kernel/postinst.d/dkms
run-parts: executing /etc/kernel/postinst.d/nvidia-common
run-parts: /etc/kernel/postinst.d/nvidia-common exited with return code 20
Failed to process /etc/kernel/postinst.d at /var/lib/dpkg/info/linux-image-2.6.28.9-phc001.postinst line 1186.
dpkg: errore processando linux-image-2.6.28.9-phc001 (--install):
il sottoprocesso post-installation script ha restituito un codice di errore 2
Sono occorsi degli errori processando:
linux-image-2.6.28.9-phc001

ivanhoe1024
April 28th, 2009, 01:51 PM
Wow, you're my hero!! Ok, I'm downloading them... Just a question: after I downloaded them, Do I have to patch them looking at http://www.linux-phc.org/forum/viewtopic.php?f=13&t=2, or are they just patched??
Thanks a lot!!

PS. I installed your two packages, but I have this error. Does anyone know what does it mean??

Examining /etc/kernel/postinst.d.
run-parts: executing /etc/kernel/postinst.d/dkms
run-parts: executing /etc/kernel/postinst.d/nvidia-common
run-parts: /etc/kernel/postinst.d/nvidia-common exited with return code 20
Failed to process /etc/kernel/postinst.d at /var/lib/dpkg/info/linux-image-2.6.28.9-phc001.postinst line 1186.
dpkg: errore processando linux-image-2.6.28.9-phc001 (--install):
il sottoprocesso post-installation script ha restituito un codice di errore 2
Sono occorsi degli errori processando:
linux-image-2.6.28.9-phc001


Ok, I fixed all... Now I've got just to patch the module (I think it sin't yet, is it??)

Why don't you post the new kernel you'll compile in the future in this thread, so we can download it?? ):P

evgeny1978
April 28th, 2009, 08:59 PM
This kernel is not patched, you need to apply patch from http://www.linux-phc.org/forum/viewtopic.php?f=13&t=2. By the way I also had this stupid error with /etc/kernel/postinst.d/nvidia-common, I didn't try to figure out what is the problem here, just removed this file temporarily when was installing kernel, after installation put it back. How did you fix this error?

tocoli
April 29th, 2009, 11:43 AM
It appears that with Jaunty the ACPI stuff is now in the kernel rather than in a module which requires you to patch and build the kernel. Having never done this before I decided to take the plunge and give it a go! I followed the instructions here http://beginlinux.wordpress.com/2008/12/03/how-to-compile-an-ubuntu-810-kernel/ and it was pretty straight forward if time consuming.

I have created a script to simplify the process. Create a folder where you have write access. Put the following script in that folder, buildKernel:

#!/bin/sh
if [ "$1" = "" ]; then
echo "Usage: $N {version number}" >&2;
exit 1;
fi
start=`date`
echo "Started : $start"
bunzip2 -c /usr/src/linux-source-2.6.28.tar.bz2 | tar xp
cd linux-source-2.6.28
cp /boot/config-`uname -r` ./.config
patch -p1 < ../linux-phc-0.3.2-kernel-vanilla-2.6.26.patch
make-kpkg clean
fakeroot make-kpkg --initrd --append-to-version=-rb${1} kernel_image kernel_headers
cd ..
rm -rf linux-source-2.6.28
echo "Started : $start"
echo "Ended : `date`"

You can replace the rb in --append-to-version=-rb${1} with your initials. You can then make it executable and run it as "buildKernel 2" where 2 is the version number you want to assign.

It takes up about 4GB during the build process (which the last line in the script deletes) to build the 2 deb packages which are about 300MB. The build took about 2 hours on my machine. You can then install the 2 packages and use the undervolting as you did when it was a module.

Hope this helps
Ray

This script above aint ok in my Ubuntu (Jaunty, 2.6.28.11).
After the build there aint any acpi-cpufreq.ko...
I ve just recomplied the kernel on PHC-forum way, and patch with phc-intel-0.3.2-5 offtree package. It's working fine.

m4cph1sto
April 30th, 2009, 01:27 PM
I'm experiencing CPU overheating after upgrading to Jaunty. There are some other threads on this issue, but readers of this thread seem to have some expertise. My Pentium M/centrino laptop has always used speedstep-centrino by default, and I used to be able to switch to acpi_cpufreq by just blacklisting speedstep-centrino and loading acpi_cpufreq. Now that they are hard-coded into the kernel, I don't know how to do this. I'm wondering if switching from speedstep-centrino to acpi_cpufreq, or vise-versa, would fix the overheating issue. Is there any way to do this now (without recompiling the entire kernel)?

ivanhoe1024
April 30th, 2009, 09:38 PM
This kernel is not patched, you need to apply patch from http://www.linux-phc.org/forum/viewtopic.php?f=13&t=2. By the way I also had this stupid error with /etc/kernel/postinst.d/nvidia-common, I didn't try to figure out what is the problem here, just removed this file temporarily when was installing kernel, after installation put it back. How did you fix this error?

I fixed it just in the same way, I can't understand what is the matter with nvidia-common... But it's not a problem of your kernel, because I've read of people in other forum with the same problem...

zcats
May 1st, 2009, 05:03 AM
So, using Jaunty PHC control now requires rebuilding and patching the kernel. There is an easier way!- download a patched kernel.

See the launchpad ppa for linux-PHC:

https://launchpad.net/~linux-phc/+archive/ppa

>add this ppa to sources.list and import key
>install updates (will include the patched undervolt kernel)
>reboot
>set vids using echo by editing rc.local as I described earlier in this thread
i.e. my optimal vids were:
echo "17:19 14:12 12:18 10:4 8:1 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls


:guitar:Done
zcat:)

ivanhoe1024
May 3rd, 2009, 05:39 PM
So, using Jaunty PHC control now requires rebuilding and patching the kernel. There is an easier way!- download a patched kernel.

See the launchpad ppa for linux-PHC:

https://launchpad.net/~linux-phc/+archive/ppa

>add this ppa to sources.list and import key
>install updates (will include the patched undervolt kernel)
>reboot
>set vids using echo by editing rc.local as I described earlier in this thread
i.e. my optimal vids were:
echo "17:19 14:12 12:18 10:4 8:1 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls


:guitar:Done
zcat:)

I asked The Fallen (phc developer) about this repository, and this is his answer:

this ppa is ours, we are currently trying to create it. There is already a kernel you can use but it will replace your default ubuntu kernel and will be replaced on the next ubuntu kernel update.

You see, we do not know how to set other version numbers to the ppa.
As soon as we solved this problem the ppa will be published.

Hope you'll find it useful, bye

jmmL
May 3rd, 2009, 06:05 PM
I asked The Fallen (phc developer) about this repository, and this is his answer:

this ppa is ours, we are currently trying to create it. There is already a kernel you can use but it will replace your default ubuntu kernel and will be replaced on the next ubuntu kernel update.

You see, we do not know how to set other version numbers to the ppa.
As soon as we solved this problem the ppa will be published.

Hope you'll find it useful, bye

To set the correct version number you need to add one and suffix ~ppaN

I don't know what the current kernel version is on jaunty, but say it's 2.6.28-11, then the maintainers of that ppa need to put 2.6.28-12~ppa1 .

I'm pretty sure that's right, anyone with more experience feel free to correct me. I'm new to all this ppa maintaining stuff! :D

M4rotku
May 3rd, 2009, 07:57 PM
Can someone post the modified kernel for:

2.6.24-23



Thanks,
M4rotku

mister_playboy
May 7th, 2009, 06:10 PM
The modified kernel works like a charm! Now everything is working perfectly in 9.04 for me (other than my Intel GMA965 graphics, anyway)!

Thank you so much.

rk.
May 13th, 2009, 02:49 AM
Hi,
I try to build a 2.6.28 Jaunty kernel with a modified versionnumber INSIDE PPA, but it failed.

************************************************** ****************************
FIRST Try:
- CONFIG_DEBUG_INFO >>> OFF
- CONFIG_LOCALVERSION >>> "phc0"
- apply linux-phc patch 0.3.2 (undervolting patch)
- add ~ppa0 to Changelog


FULL-LOG:
http://launchpadlibrarian.net/25179325/buildlog_ubuntu-jaunty-i386.linux_2.6.28-11.42~ppa2_FAILEDTOBUILD.txt.gz (http://launchpadlibrarian.net/25179325/buildlog_ubuntu-jaunty-i386.linux_2.6.28-11.42%7Eppa2_FAILEDTOBUILD.txt.gz)


# The main image
install -m644 -D /build/buildd/linux-2.6.28/debian/build/build-generic/arch/i386/boot/bzImage \
/build/buildd/linux-2.6.28/debian/linux-image-2.6.28-11-generic/boot/vmlinuz-2.6.28-11-generic
install -m644 /build/buildd/linux-2.6.28/debian/build/build-generic/.config \
/build/buildd/linux-2.6.28/debian/linux-image-2.6.28-11-generic/boot/config-2.6.28-11-generic
install -m644 /build/buildd/linux-2.6.28/debian/abi/2.6.28-11.42~ppa2/i386/generic \
/build/buildd/linux-2.6.28/debian/linux-image-2.6.28-11-generic/boot/abi-2.6.28-11-generic
install -m644 /build/buildd/linux-2.6.28/debian/build/build-generic/System.map \
/build/buildd/linux-2.6.28/debian/linux-image-2.6.28-11-generic/boot/System.map-2.6.28-11-generic
makedumpfile -g /build/buildd/linux-2.6.28/debian/linux-image-2.6.28-11-generic/boot/vmcoreinfo-2.6.28-11-generic \
-x /build/buildd/linux-2.6.28/debian/build/build-generic/vmlinux
get_debug_info: Can't create a handle for a new debug session.
makedumpfile Failed.
make: *** [install-generic] Error 1
dpkg-buildpackage: failure: /usr/bin/fakeroot debian/rules binary gave error exit status 2
************************************************** ****************************
SECOND Try:
- remove of MAKEDUMPFILE in deban/rules.d/binary-arch.mk

FULL-LOG:
http://launchpadlibrarian.net/25099133/buildlog_ubuntu-jaunty-i386.linux_2.6.28-11.42~ppa1_FAILEDTOBUILD.txt.gz (http://launchpadlibrarian.net/25099133/buildlog_ubuntu-jaunty-i386.linux_2.6.28-11.42%7Eppa1_FAILEDTOBUILD.txt.gz)


#
# Remove files which are generated at installation by postinst, except for
# modules.order.
#
mv /build/buildd/linux-2.6.28/debian/linux-image-2.6.28-11-generic/lib/modules/2.6.28-11-generic/modules.order \
/build/buildd/linux-2.6.28/debian/linux-image-2.6.28-11-generic/lib/modules/2.6.28-11-generic/_modules.order
mv: cannot stat `/build/buildd/linux-2.6.28/debian/linux-image-2.6.28-11-generic/lib/modules/2.6.28-11-generic/modules.order': No such file or directory
make: *** [install-generic] Error 1
dpkg-buildpackage: failure: /usr/bin/fakeroot debian/rules binary gave error exit status 2 ************************************************** ****************************


I don't know what's wrong with the build. I read the Kernel Build Guide of Ubuntu, but I can't find the solution. Why the buildprocess fail with a modified Versionnumber?

Mr Pink57
May 16th, 2009, 02:29 PM
I am not sure if this is really working or my values are sticking.

The stress test went to -1 then stopped so it never actually crashed. And I only saw one value in my list which was 15 1 and that does not work, so I did 17:1 and my system completely freezes once I hit enter. So I am a little confused I guess any insight would be great.

pink

Mr Pink57
May 17th, 2009, 07:52 AM
I am not sure if this is really working or my values are sticking.

The stress test went to -1 then stopped so it never actually crashed. And I only saw one value in my list which was 15 1 and that does not work, so I did 17:1 and my system completely freezes once I hit enter. So I am a little confused I guess any insight would be great.

pink

I did end up getting this to work I set my second value to my lowest cpu mhz second value for all (only 2) and now I am no joke 30c cooler, that does include me taking a air can to this laptop.

pink

skinnie
May 19th, 2009, 05:34 AM
I asked The Fallen (phc developer) about this repository, and this is his answer:

this ppa is ours, we are currently trying to create it. There is already a kernel you can use but it will replace your default ubuntu kernel and will be replaced on the next ubuntu kernel update.

You see, we do not know how to set other version numbers to the ppa.
As soon as we solved this problem the ppa will be published.

Hope you'll find it useful, bye

how do I know if phc is working with this method?it is the same method as the old one?

adambro7
May 24th, 2009, 08:20 AM
Hi,
I try to build a 2.6.28 Jaunty kernel with a modified versionnumber INSIDE PPA, but it failed.
(...)
I don't know what's wrong with the build. I read the Kernel Build Guide of Ubuntu, but I can't find the solution. Why the buildprocess fail with a modified Versionnumber?

I'm not an expert but this may help:
- Building your source package (https://help.launchpad.net/Packaging/PPA#Building%20your%20source%20package) - PPA help explains versioning
- Kernel DKMS Package (https://help.ubuntu.com/community/Kernel/DkmsDriverPackage) - describes how to compile dynamic kernel modules and since ACPI is a module (compiled-in) it may help resolve ABI issues

anjie
June 8th, 2009, 05:17 AM
So, using Jaunty PHC control now requires rebuilding and patching the kernel. There is an easier way!- download a patched kernel.

See the launchpad ppa for linux-PHC:

https://launchpad.net/~linux-phc/+archive/ppa

>add this ppa to sources.list and import key
>install updates (will include the patched undervolt kernel)
>reboot
>set vids using echo by editing rc.local as I described earlier in this thread
i.e. my optimal vids were:
echo "17:19 14:12 12:18 10:4 8:1 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls


:guitar:Done
zcat:)



Hello, I've just followed the 1st 2nd 3rd step of your tips. Before setting vids, how can I check if the new kernel works? For example, if I enter this command

cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls

I get a missing device error.
Excuse me for my "too noob" questions...

Thanks,

A.

mister_playboy
June 11th, 2009, 05:07 AM
Hello, I've just followed the 1st 2nd 3rd step of your tips. Before setting vids, how can I check if the new kernel works? For example, if I enter this command

cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls

I get a missing device error.
Excuse me for my "too noob" questions...

Thanks,

A.

You have to install the modified kernel before you can set the VIDs... the module is in the kernel now. The test would be to run:


cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls

which should give you the default VIDs with the newly installed modded kernel, rather than a missing device error with the normal kernel. You then need to set the VIDs and have them echoed to run at startup as is detailed in the first post.

The process is actually easier for end users now that we have the repo. :)

anjie
June 11th, 2009, 05:30 AM
You have to install the modified kernel before you can set the VIDs... the module is in the kernel now. The test would be to run:


cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls

which should give you the default VIDs with the newly installed modded kernel, rather than a missing device error with the normal kernel. You then need to set the VIDs and have them echoed to run at startup as is detailed in the first post.

The process is actually easier for end users now that we have the repo. :)

Thanks for your answer, I also thought that the process would be easy , I've simply updated ubuntu after entering the new repo and have a reload after entering keys. When updating it downloaded again the same kernel version, and I think it has substituted the old one. It seems it has got the same name as the previous one, am I wrong? Shouldn't the name be different?

uname -r gives me:

2.6.28-11-generic

Looking in synaptic manager there undervolt packages installed such as
linux-headers-2.8.28.11-gener 2.6.28.11.43-undervolt1

Is there a way to install it? Maybe I've only downloaded it and the old one is still the "head" kernel

Thanks again!!


I ADD a part of menu.lst


kernel /boot/vmlinuz-2.6.28-11-generic root=UUID= [cut]
initrd /boot/initrd.img-2.6.28-11-generic

zcats
June 12th, 2009, 01:25 PM
Even when you have the patched kernel installed >uname-r gives
>2.6.28-11-generic
The way to test if the patched kernel is installed is to run
>cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
it should return YOUR vids (mine are..)
>17:19 14:12 12:8 10:4 8:1 6:1
If the above command does not give vids you have not got the patched kernel installed OR you are not booting the correct kernel. Check synaptic to see if the "installed version" column shows 2.6.28-11-generic~undervolt.
If OK then check menu.lst to see that you are booting the correct kernel!
******BTW i did not need to change anything in menu.lst....seems that the generic kernel in menu.lst points to the ~undervolt kernel without actually needing to specify this...

My section looks like (yours will have a different UUID) :
title Ubuntu 9.04, kernel 2.6.28-11-generic
uuid 9ee9e3e1-ef67-4be4-a0df-03ed23443615
kernel /boot/vmlinuz-2.6.28-11-generic root=UUID=9ee9e3e1-ef67-4be4-a0df-03ed23443615 ro splash
initrd /boot/initrd.img-2.6.28-11-generic
quiet

Hope this solves it:p

anjie
June 12th, 2009, 03:59 PM
Even when you have the patched kernel installed >uname-r gives
>2.6.28-11-generic
The way to test if the patched kernel is installed is to run
>cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
it should return YOUR vids (mine are..)
>17:19 14:12 12:8 10:4 8:1 6:1
If the above command does not give vids you have not got the patched kernel installed OR you are not booting the correct kernel. Check synaptic to see if the "installed version" column shows 2.6.28-11-generic~undervolt.
If OK then check menu.lst to see that you are booting the correct kernel!
******BTW i did not need to change anything in menu.lst....seems that the generic kernel in menu.lst points to the ~undervolt kernel without actually needing to specify this...

My section looks like (yours will have a different UUID) :
title Ubuntu 9.04, kernel 2.6.28-11-generic
uuid 9ee9e3e1-ef67-4be4-a0df-03ed23443615
kernel /boot/vmlinuz-2.6.28-11-generic root=UUID=9ee9e3e1-ef67-4be4-a0df-03ed23443615 ro splash
initrd /boot/initrd.img-2.6.28-11-generic
quiet

Hope this solves it:p


First of all thanks for answering me.
It seems there is nothing to do. As you see in my previous post I've checked synaptics and the installed version is just the undervolt one.

cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
Always: no device

my menu.lst, I've posted it above, is the same as yours. :(

I don't think I'm missing something, that's sad, my noisy fan keeps bothering and I have always to run windows :-& in order to undervolt and keep cool my cpu... what can I do? :cry:

Rizado
June 13th, 2009, 12:47 PM
I don't think this is working for me, the script goes way down to -1 without any problems. This goes for all frequencies... It doesn't seem to be any problems with the phc patch either. The temperaturer is stable at 76C throughout the testing so I don't believe it's worling at all :(

I have a Core 2 Duo T5870 and the latest 2.6.30 vanilla kernel (with patches of course).

EDIT: I got it to work! It seem that the script doesn't want to change governor on both cores (or maybe it's cpu1 that matters for me). I changed it a bit and made it change both cpu0 and cpu1 at the same time. The voltages go ridiculously low anyway but the temperature is decreasing so it is working. The two lowest frequencies is stable at 0... After 30 minutes of stress test at the highest frequency (2Ghz) the temperature has stabilized at about 65C. That is with the fan at 45%! There should be no problem on a hot day as it has a lot more fan to spin :) Right now the room temperature is about 22C
Btw, I have a HP 2230s with a 2Ghz C2D T5870 and my phc_vids is: "22 20 10 0 0"
The second value is 4 steps above crash. The others I don't know since I didn't bother letting the script finish.

I have a question too. As the two lowest frequencies have the same voltages, is it really necessary to use the lowest? Wouldn't the second lowest use the same amount of energy, or less (no wasted cycles when switching modes), when idling?

dementic
June 14th, 2009, 11:49 AM
I have a question too. As the two lowest frequencies have the same voltages, is it really necessary to use the lowest? Wouldn't the second lowest use the same amount of energy, or less (no wasted cycles when switching modes), when idling?Did the test on Windows with RmClock and it uses more power when running at 1.2Ghz with 0.85v than on 800mhz with 0.85v. I have core2duo 7250 on a dell inspiron 1520 laptop

Ares Drake
June 14th, 2009, 07:14 PM
Did the test on Windows with RmClock and it uses more power when running at 1.2Ghz with 0.85v than on 800mhz with 0.85v. I have core2duo 7250 on a dell inspiron 1520 laptop


I seem to remember that used energy scales about linearly with frequency and about ^2 with voltage. (Info must be from overclockers.com if I remember correctly)

Noahod
June 14th, 2009, 09:26 PM
I don't think this is working for me, the script goes way down to -1 without any problems. This goes for all frequencies... It doesn't seem to be any problems with the phc patch either. The temperaturer is stable at 76C throughout the testing so I don't believe it's worling at all :(

I have a Core 2 Duo T5870 and the latest 2.6.30 vanilla kernel (with patches of course).

EDIT: I got it to work! It seem that the script doesn't want to change governor on both cores (or maybe it's cpu1 that matters for me). I changed it a bit and made it change both cpu0 and cpu1 at the same time. The voltages go ridiculously low anyway but the temperature is decreasing so it is working. The two lowest frequencies is stable at 0... After 30 minutes of stress test at the highest frequency (2Ghz) the temperature has stabilized at about 65C. That is with the fan at 45%! There should be no problem on a hot day as it has a lot more fan to spin :) Right now the room temperature is about 22C
Btw, I have a HP 2230s with a 2Ghz C2D T5870 and my phc_vids is: "22 20 10 0 0"
The second value is 4 steps above crash. The others I don't know since I didn't bother letting the script finish.


Hi, I have the same problem, mine goes to -1 and stops. How did you edit the script to make it change it for both cores?

Thanks

XRayA4T
June 15th, 2009, 02:09 PM
This script above aint ok in my Ubuntu (Jaunty, 2.6.28.11).
After the build there aint any acpi-cpufreq.ko...
I ve just recomplied the kernel on PHC-forum way, and patch with phc-intel-0.3.2-5 offtree package. It's working fine.

THe script builds the .deb packages with the new kernel and headers. You still need to install the packages you build.
Ray

mister_playboy
June 19th, 2009, 05:22 AM
Kernel 2.6.28.13 is available in update manager, but you'll want to hold off on upgrading for now unless you are okay with losing your undervolting! :)

Uhuu
June 29th, 2009, 01:22 PM
Is the kernel updated yet at the phc repos?

sarah.fauzia
June 29th, 2009, 03:05 PM
I'm an Arch Linux user now, and I've tried the script again, and it works great. The only catch is that I'm having random lock-ups...

So, to try to figure out why, I tried the script in three different states:
1) My computer with the lowest brightness set, wireless not on
2) With the highest brightness set, wireless on, AC adapter connected
3) With the highest brightness set, wireless on, AC not connected

Here are the values I get (respectively):
[sara@sara-thinkpad without_ac]$ cat phc_tweaked_vids
20 17 1 1
[sara@sara-thinkpad with_ac]$ cat phc_tweaked_vids
16 1 1 -1
[sara@sara-thinkpad without_ac_high]$ cat phc_tweaked_vids
16 15 1 1


My machine is C2D, an X61 tablet, with the latest kernel 2.6.30. I'm getting the lock-ups with using the first set of values (20 17 1 1) on both cores.


[sara@sara-thinkpad ~]$ cat /sys/devices/system/cpu/cpu1/cpufreq/phc_controls
10:20 9:17 6:1 136:1

The default values: 36 25 21 11

So far, just bumping up each of the values (20 17 1 1) by two seems to have fixed the problem, but I wonder why the script's values didn't work (when the script had already bumped the values by two based off the minimum my computer could take).

mister_playboy
July 5th, 2009, 10:22 PM
Is the kernel updated yet at the phc repos?

Not yet... [-o<

Shikaku2
July 6th, 2009, 02:45 AM
I wonder if it works with an AMD Turion X2 Laptop. I'll wait for the patch and mess with it when it comes out.

Kiddion
July 6th, 2009, 11:20 AM
I wonder if it works with an AMD Turion X2 Laptop. I'll wait for the patch and mess with it when it comes out.

Depends on the AMD Turion X2 you're talking about... What family does it belong to, as mentioned in /proc/cpuinfo? If it is 17, then it is not supported at the moment... But I am working on it.
If it is <16 it is already supported. And with "direct_transitions" enabled, you can even unlock new frequencies.

Shikaku2
July 6th, 2009, 07:57 PM
processor : 0
vendor_id : AuthenticAMD
cpu family : 15
model : 72
model name : AMD Turion(tm) 64 X2 Mobile Technology TL-50

Oh! I'll reread this whole thread and check it out then.

Thanks :cool:

philcamlin
July 6th, 2009, 07:59 PM
very cool post

i should try it on my laptop :popcorn:

Shikaku2
July 6th, 2009, 08:56 PM
Depends on the AMD Turion X2 you're talking about... What family does it belong to, as mentioned in /proc/cpuinfo? If it is 17, then it is not supported at the moment... But I am working on it.
If it is <16 it is already supported. And with "direct_transitions" enabled, you can even unlock new frequencies.

I reread this thread and even installed the undervolt patch from the supplied repositories. But I can't get it to work right. Can anyone help me?

Running cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls gives does not exist.

processor : 0
vendor_id : AuthenticAMD
cpu family : 15
model : 72
model name : AMD Turion(tm) 64 X2 Mobile Technology TL-50

This is my CPU.

Kiddion
July 7th, 2009, 04:20 AM
I reread this thread and even installed the undervolt patch from the supplied repositories. But I can't get it to work right. Can anyone help me?

Running cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls gives does not exist.

processor : 0
vendor_id : AuthenticAMD
cpu family : 15
model : 72
model name : AMD Turion(tm) 64 X2 Mobile Technology TL-50

This is my CPU.
That's perhaps because I only wrote an out-of-tree AMD k8 patch and therefore it's probably not included in the PHC ppa kernel (but you will need it or another kernel without built-in powernow-k8 driver).

Just install "dkms" if you don't have it (`sudo apt-get install dkms`) download the driver, unpack it somewhere and run `sudo make dkms_install`. Your driver will be called "phc-k8" and should show up in `lsmod`.
To unlock all fids, you need to edit /etc/modprobe.d/phc-k8.conf and uncomment the line with "#option phc-k8 direct_transitions=1".

There's a patch for Gentoo that can be applied on top of the kernel, I'll ask the-fallen whether this can be included in the PPA, so it will be a part of the ppa kernel as well...

Shikaku2
July 8th, 2009, 08:42 AM
That's perhaps because I only wrote an out-of-tree AMD k8 patch and therefore it's probably not included in the PHC ppa kernel (but you will need it or another kernel without built-in powernow-k8 driver).

Just install "dkms" if you don't have it (`sudo apt-get install dkms`) download the driver, unpack it somewhere and run `sudo make dkms_install`. Your driver will be called "phc-k8" and should show up in `lsmod`.
To unlock all fids, you need to edit /etc/modprobe.d/phc-k8.conf and uncomment the line with "#option phc-k8 direct_transitions=1".

There's a patch for Gentoo that can be applied on top of the kernel, I'll ask the-fallen whether this can be included in the PPA, so it will be a part of the ppa kernel as well...

This is so strange... I did it right I think but it's not in lsmod at all.

Here's what I did. I have the repository undervolt kernel, it's downloaded and installed.

It wasn't working.

I already had DKMS. I downloaded the latest AMD phc from linux-phc.org. I went to the directory and did sudo make dkms_install. Reboot.

I still get nothing in lsmod about it nor does the phc options appear in the cpu0/cpufreq folder.

I make sure it loads by editing the /etc/modules and adding phc-k8. It doesn't load.

I then BLACKLIST powernow-k8 to see if it was a conflict.

I check dmesg and this is the only line about PHC i get:

[ 15.730675] phc-k8: Found 1 AMD Turion(tm) 64 X2 Mobile Technology TL-50 processors (2 cpu cores) (version 2.20.00)

It's still not in lsmod though :(

Kiddion
July 8th, 2009, 09:27 AM
This is so strange... I did it right I think but it's not in lsmod at all.

Here's what I did. I have the repository undervolt kernel, it's downloaded and installed.

It wasn't working.

I already had DKMS. I downloaded the latest AMD phc from linux-phc.org. I went to the directory and did sudo make dkms_install. Reboot.

I still get nothing in lsmod about it nor does the phc options appear in the cpu0/cpufreq folder.

I make sure it loads by editing the /etc/modules and adding phc-k8. It doesn't load.

I then BLACKLIST powernow-k8 to see if it was a conflict.

I check dmesg and this is the only line about PHC i get:

[ 15.730675] phc-k8: Found 1 AMD Turion(tm) 64 X2 Mobile Technology TL-50 processors (2 cpu cores) (version 2.20.00)

It's still not in lsmod though :(

Hmmm, what are the outputs of:

uname -a
dmesg|grep k8
lsmod|grep k8
modprobe -l *k8*
dkms status

BTW, you can also contact me directly, see at the top of phc-k8.c for my email ;)

Shikaku2
July 8th, 2009, 09:43 AM
uname -a
dmesg|grep k8
lsmod|grep k8
modprobe -l *k8*
dkms status

computer:~$ uname -a
Linux computer-laptop 2.6.28-11-generic #43~undervolt1-Ubuntu SMP Fri Apr 17 18:32:02 UTC 2009 i686 GNU/Linux
computer:~$ dmesg|grep k8
[ 2.364875] powernow-k8: Found 1 AMD Turion(tm) 64 X2 Mobile Technology TL-50 processors (2 cpu cores) (version 2.20.00)
[ 2.364976] powernow-k8: 0 : fid 0x8 (1600 MHz), vid 0x13
[ 2.365032] powernow-k8: 1 : fid 0x0 (800 MHz), vid 0x14
[ 15.754779] phc-k8: Found 1 AMD Turion(tm) 64 X2 Mobile Technology TL-50 processors (2 cpu cores) (version 2.20.00)
[ 18.456738] phc-k8: Found 1 AMD Turion(tm) 64 X2 Mobile Technology TL-50 processors (2 cpu cores) (version 2.20.00)
computer:~$ lsmod|grep k8
k8temp 12416 0
computer:~$ modprobe -l *k8*
kernel/drivers/hwmon/k8temp.ko
kernel/drivers/mtd/maps/ck804xrom.ko
updates/dkms/phc-k8.ko
computer:~$ dkms status
phc-k8, 0.4.1, 2.6.28-11-generic, i686: installed

I found the email too btw. If I need further assistance I'll email.

Kiddion
July 8th, 2009, 10:13 AM
computer:~$ uname -a
Linux computer-laptop 2.6.28-11-generic #43~undervolt1-Ubuntu SMP Fri Apr 17 18:32:02 UTC 2009 i686 GNU/Linux
computer:~$ dmesg|grep k8
[ 2.364875] powernow-k8: Found 1 AMD Turion(tm) 64 X2 Mobile Technology TL-50 processors (2 cpu cores) (version 2.20.00)
[ 2.364976] powernow-k8: 0 : fid 0x8 (1600 MHz), vid 0x13
[ 2.365032] powernow-k8: 1 : fid 0x0 (800 MHz), vid 0x14
[ 15.754779] phc-k8: Found 1 AMD Turion(tm) 64 X2 Mobile Technology TL-50 processors (2 cpu cores) (version 2.20.00)
[ 18.456738] phc-k8: Found 1 AMD Turion(tm) 64 X2 Mobile Technology TL-50 processors (2 cpu cores) (version 2.20.00)


I found the email too btw. If I need further assistance I'll email.

I seems the powernow-k8 module is (still) built-in, I'll contact the-fallen, that shouldn't have happened and it will be fixed ASAP. So it's the ppa kernel that is causing this to fail...

Kiddion
July 12th, 2009, 05:30 PM
There's a newer kernel available with the powernow-k8 patch integrated at https://launchpad.net/~linux-phc/+archive/ppa

The driver is built as a module, so you can even override it by a different PHC K8 patch in the future.

mister_playboy
July 14th, 2009, 06:32 AM
Ahhh... there's the new kernel so we can update now! :)

Thank you to the repo maintainers for helping out n00bs such as myself.

EDIT: I updated to the new kernel from the repo, but I don't have undervolting... huh? It is listed as installed, but I don't have PHC. I just downloaded all the available updates in Update Manager... do we need to do something else? I only have two kernel images in /boot, so I believe I am booting to the modified kernel when choosing 2.6.28.13... and 2.6.28.11 still works correctly. What's going on?

winnibob
July 16th, 2009, 01:22 PM
EDIT: I updated to the new kernel from the repo, but I don't have undervolting... huh? It is listed as installed, but I don't have PHC. I just downloaded all the available updates in Update Manager... do we need to do something else? I only have two kernel images in /boot, so I believe I am booting to the modified kernel when choosing 2.6.28.13... and 2.6.28.11 still works correctly. What's going on?
I have updated my system yesterday with kernel 2.6.28.13 from the ppa and it is working fine on my dual core.

Kiddion
July 18th, 2009, 05:02 PM
EDIT: I updated to the new kernel from the repo, but I don't have undervolting... huh? It is listed as installed, but I don't have PHC. I just downloaded all the available updates in Update Manager... do we need to do something else? I only have two kernel images in /boot, so I believe I am booting to the modified kernel when choosing 2.6.28.13... and 2.6.28.11 still works correctly. What's going on?
There was a problem for Centrino's (the depricated speedstep-centrino module was built-in and therefore used instead of the PHC acpi-cpufreq module). This should be solved in the latest 2.6.28.13-generic version 2.6.28-13.46~undervolt3.

asuna
July 19th, 2009, 05:49 AM
First of all thanks for answering me.
It seems there is nothing to do. As you see in my previous post I've checked synaptics and the installed version is just the undervolt one.

cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
Always: no device

my menu.lst, I've posted it above, is the same as yours. :(



I've been following the steps to install the linux_phc module, and I got as far as ^anjie

I've downloaded and installed the 2.6.28-13.46~undervolt3 kernel from the PPA (via Update Manager), rebooted to it (although the grub menu says 2.6.28-13-generic), and I got this:

cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls : No such file or directory

I tried: cat: /sys/devices/system/cpu/cpu0: Is a directory

lsmod | grep acpi_cpufreq gives nothing (blank)

menu.lst looks normal, contains both 2.6.28-13-generic and 2.6.28-11-generic. Do I need to add the 2.6.28-13.46~undervolt3 entry to the list?

It seems as if I never installed the undervolt3 kernel, even though synaptics tells me its installed. Can anyone help?

I'm using an Intel Core 2 Duo T5500, dual boot with windows xp

Schnitzelpudding
July 19th, 2009, 08:54 AM
No (automatic) fun here either.

Clean install of 9.04, updated everything (including kernel to 2.6.28-13), removed 2.6.28-11, added the PPA, ran Update Manager and let it install its stuff. This seems to have overwritten the original kernel, the acpi-cpufreq module exists but isn't loaded automatically ("CPU frequency scaling unsupported" popup after login and processor stuck at full speed). I've added it to /etc/modules and that seems to be working for now... is this supposed to happen? This is on a Core Duo (T2350) laptop, so nothing particularly exotic.

Kiddion
July 19th, 2009, 11:51 AM
Did you add the acpi_cpufreq module to /etc/modules ? The modules isn't loaded automatically by the default Ubuntu startup scripts, as those suppose that the modules are built-in. If the /sys/devices/system/cpu/cpu0/cpufreq/ directory isn't there, the module has never been loaded.

Shikaku2
July 19th, 2009, 03:07 PM
Oops, I don't know what I'm doing, ignore me.

asuna
July 19th, 2009, 11:30 PM
Ok thanks for all the help

EDIT:
Finally got it to work!

After I downloaded and used PHC Tool

From http://linux.aldeby.org/linux-phc-cpu-undervolting.html

"There is no package, you have to download a subversion snapshot via:

sudo apt-get install subversion

svn co http://phctool.googlecode.com/svn/trunk/ phctool

The tool has a Analysis tab as you can see in the screenshot.

To get this to work, you first need to

sudo modprobe msr"

adempewolff
July 21st, 2009, 05:35 PM
I hope this hasn't already been addressed in the thread. I tried looking for a while but did not see anything.

Nothing happens when I enter "lsmod | grep acpi_cpufreq". However I am using an Intel Core 2 Duo (which the howto states it has been tested with) and cannot figure out for the life of me why my kernal would be using a module for Centrino processors... (if it matters I'm also using 9.04, 2.6.28-13-generic)

Am I missing something here? Is there any other reason why I wouldn't get any output from that command?

hegoburu
July 23rd, 2009, 10:05 AM
Ok maybe someone could help me out here. I re compiled the kernel per phc forum instructions, installed phc-k8, rebooted. Lsmod gives me phc-k8 as loaded, checking scaling_driver in cpufreq reports phc-k8, however, there are no phc-specific files in the cpufreq directory. ?? Any ideas?

Kiddion
July 24th, 2009, 06:47 PM
I hope this hasn't already been addressed in the thread. I tried looking for a while but did not see anything.
[...]
Am I missing something here? Is there any other reason why I wouldn't get any output from that command?
It was mentioned before, but you'll have to add a line containing "acpi-cpufreq" to /etc/modules

Ok maybe someone could help me out here. I re compiled the kernel per phc forum instructions, installed phc-k8, rebooted. Lsmod gives me phc-k8 as loaded, checking scaling_driver in cpufreq reports phc-k8, however, there are no phc-specific files in the cpufreq directory. ?? Any ideas?

Your processor isn't supported (yet). The current phc-k8 driver does not support undervolting for family 10h and family 11h processors (Phenoms and recent Turion X2 processors).

mister_playboy
July 24th, 2009, 09:55 PM
There was a problem for Centrino's (the depricated speedstep-centrino module was built-in and therefore used instead of the PHC acpi-cpufreq module). This should be solved in the latest 2.6.28.13-generic version 2.6.28-13.46~undervolt3.

Hmm... I downloaded the newer version and it still doesn't work for me. My laptop is a Pentium dual-core.

Kiddion
July 25th, 2009, 10:28 AM
Hmm... I downloaded the newer version and it still doesn't work for me. My laptop is a Pentium dual-core.
If you added a line containing "acpi-cpufreq" to /etc/modules and it is still not working (but the module *is* loaded), then I don't know what is happening either, the-fallen has to answer that... I don't know if he watches this forum, perhaps it is best to start a new topic at http://www.linux-phc.org then.

adempewolff
July 26th, 2009, 10:10 PM
It was mentioned before, but you'll have to add a line containing "acpi-cpufreq" to /etc/modules

Thank you for your advice but it hasn't worked for me. I added the line:

# /etc/modules: kernel modules to load at boot time.
#
# This file contains the names of kernel modules that should be loaded
# at boot time, one per line. Lines beginning with "#" are ignored.

lp
sbp2
ndiswrapper
acpi-cpufreq


and rebooted but I am still not getting any output from the lsmod:

austin@austin-laptop:~$ lsmod | grep acpi_cpufreq
austin@austin-laptop:~$

My kernel is 2.6.28-13-generic #45-Ubuntu, although I will be upgrading to amd64 this week when I get a new hdd. I've heard rumors that jaunty kernels do not have acpi_cpufreq as a module. I know that acpi_cpufreq works because I use it for the ondemand frequency governor. I just can't get it to show up for the first step of this howto! ](*,)

Any advice would be greatly appreciated!

mark540
July 26th, 2009, 10:13 PM
Thank you very much

Kiddion
July 28th, 2009, 03:11 AM
My kernel is 2.6.28-13-generic #45-Ubuntu, although I will be upgrading to amd64 this week when I get a new hdd. I've heard rumors that jaunty kernels do not have acpi_cpufreq as a module. I know that acpi_cpufreq works because I use it for the ondemand frequency governor. I just can't get it to show up for the first step of this howto! ](*,)

Any advice would be greatly appreciated!
You WILL need to use the kernel from the Linux-PHC PPA for Ubuntu 9.04 as it is mentioned a couple of times in this topic. That is because Ubuntu decided to built all frequency scaling drivers into the kernel, eliminating all possibilities for undervolting using the stock Ubuntu kernel.
I wish someone could update the first post, because it is so outdated, it does not apply at all to Ubuntu 9.04...

Snakekick
July 30th, 2009, 03:48 PM
Hello, i have a problem .
i use a desktop with q6600 intel quadcore cpu with 2.6.28-13-generic #46~undervolt5 kernel
with windows i use rmclock and i can undervolt the cpu.
but with ubuntu that not working.
phc run and i can see phc_controls and the rest:

cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
9:35 8:33 7:30 6:27

but when i change the setting nothing happen.
i have try 9:1 8:1 7:1 6:1
and phc_controls and phc_vids say the new setting but lmsensors say that nothing change.

htrex
August 3rd, 2009, 01:00 PM
I've sent an idea on brainstorm to ship karmic koala with acpi-cpufreq as a module or patch directly the kernel instead:

http://brainstorm.ubuntu.com/idea/20847/

please vote for it if you care about this.

ArmenianLeader4
August 3rd, 2009, 06:49 PM
I would do this, but I dont know if my PC can handle another crash

mobad
August 22nd, 2009, 05:24 AM
I installed the newest ppa kernel (it's -15 now) and I'm trying to modprobe acpi_cpufreq and it gives me:
FATAL: Error inserting acpi_cpufreq (/lib/modules/2.6.28-15-generic/kernel/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.ko): No such device

I've got a AMD Athlon(tm) Neo Processor MV-40.

"lsmod | grep k8" gives me k8temp and "dmesg | grep k8" gives me nothing.

I don't know whether it supports my processor yet but I should be at least able to run the module...

EDIT: I guess I was try to mount the Intel module...
For some reason the kernel doesn't come with phc_k8 so I compiled it.
I get "8:22 0:22" in phc_controls now.
But... changing the 22s does nothing so I will assume AMD Neo support is has not been added yet, so I will wait patiently...
Supposedly RMClock works amazingly on the processor.

Kiddion
August 23rd, 2009, 04:30 PM
I installed the newest ppa kernel (it's -15 now) and I'm trying to modprobe acpi_cpufreq and it gives me:
FATAL: Error inserting acpi_cpufreq (/lib/modules/2.6.28-15-generic/kernel/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.ko): No such device

I've got a AMD Athlon(tm) Neo Processor MV-40.

"lsmod | grep k8" gives me k8temp and "dmesg | grep k8" gives me nothing.

I don't know whether it supports my processor yet but I should be at least able to run the module...
Hi, the howto on the first post of this thread is outdated. For Intel processors you need to add "acpi-cpufreq" to /etc/modules, but for AMD processors you need to add "powernow-k8" instead to run the Linux-PHC PPA kernel (with Intel and AMD patches included). Please try to load "powernow-k8" and please please contact me with your findings (I'm the writer/maintainer of the phc-k8 driver).

ashcroft3000
September 7th, 2009, 12:40 AM
Hey there, forum mateyz!

I'm having a hard time getting usable voltages with this script (Running Jaunty with 2.6.28-15-generic #50~undervolt2-Ubuntu). "cat /sys/devices/system/cpu/cpu0/cpufreq/phc_default_controls" returns "10:44 8:32 6:19". Since I've got a CoreDuo (Intel CoreDuo T2300 @ 1.66 GHz), 19 is the lowest VID possible on this CPU, right?

Just like for Pluies (http://ubuntuforums.org/member.php?u=809462), Mr Pink57 (http://ubuntuforums.org/member.php?u=175982), Rizado (http://ubuntuforums.org/member.php?u=52168) and Noahod (http://ubuntuforums.org/member.php?u=34070) (see links below), the OP's script doesn't stop before VID=-1 on my machine. "So far, so good!", I thought and echoed "10:19 8:19 6:19" into "...cpufreq/phc_default_controls". Well, machine dies as soon GDM is started (before that, /etc/rc.local is successfully executed, btw). So, I guess, I shouldn't use 19 for the first two VIDs...

Question: How can I get this script to work, so it returns meaningful values? (Yep, I did stress core #2, as well...)

Thanks in advance!
Richard

http://ubuntuforums.org/showthread.php?p=7291038#post7291038
http://ubuntuforums.org/showthread.php?p=7450495#post7450495
http://ubuntuforums.org/showthread.php?p=7457918#post7457918

indosupremacy
September 10th, 2009, 05:54 AM
ouch , my laptop using speed*.centrino model . Wait for another tutorial for my kind of core

beezwings
September 16th, 2009, 01:38 PM
Hi~

I'm a complete nooB. I've just upgraded to Jaunty and lost my previous undervolting settings. I've added the repositories from https://launchpad.net/~linux-phc/+archive/ppa but now what am I supposed to do? There's a long list of "files included" but I can't seem to find any one particular file to download or search for in synaptic. Help! (Sorry so new...all the more complex posts in this thread were way beyond me!)

beez

winnibob
September 20th, 2009, 06:23 AM
Hi~

I'm a complete nooB. I've just upgraded to Jaunty and lost my previous undervolting settings. I've added the repositories from https://launchpad.net/~linux-phc/+archive/ppa but now what am I supposed to do? There's a long list of "files included" but I can't seem to find any one particular file to download or search for in synaptic. Help! (Sorry so new...all the more complex posts in this thread were way beyond me!)

beez

You just have to update your system with System->Update_Manager after adding the ppa, and the modified kernel should be available for update.

beezwings
September 21st, 2009, 09:25 PM
You just have to update your system with System->Update_Manager after adding the ppa, and the modified kernel should be available for update.

I've updated a couple of times, but nothing happens except for the normal security updates. It doesn't offer to update the kernel. What to do? I'm running 9.04 with 2.6.28-15. Thanks!

winnibob
September 23rd, 2009, 12:23 PM
I've updated a couple of times, but nothing happens except for the normal security updates. It doesn't offer to update the kernel. What to do? I'm running 9.04 with 2.6.28-15. Thanks!

Has your problem been solved?

If not, please check which version you have for the following packets, just to be sure that the ~undervolt version of the kernel is not already installed on your system :

linux-headers-2.6.28-15
linux-headers-2.6.28-15-generic
linux-image-2.6.28-15-generic

beezwings
September 23rd, 2009, 01:24 PM
Has your problem been solved?

If not, please check which version you have for the following packets, just to be sure that the ~undervolt version of the kernel is not already installed on your system :

linux-headers-2.6.28-15
linux-headers-2.6.28-15-generic
linux-image-2.6.28-15-generic

Not solved yet...I couldn't find anything with 2.6.28-15 ~undervolt in the repositories, so I tried installing 2.6.28-13 ~undervolt a few days ago. Now I have some strange mix. What is installed is the following:


linux-headers-2.6.28-13 ~undervolt5
linux-headers-2.6.28-13-generic ~undervolt5
linux-image-2.6.28-13-generic ~undervolt5
linux-image-2.6.28-15-generic
linux-image-generic (version 2.6.28-15.20)

Thanks for your help!

Ev1L
September 23rd, 2009, 01:26 PM
you are sure you have these lines in /etc/apt/sources.list?

deb http://ppa.launchpad.net/linux-phc/ppa/ubuntu jaunty main
deb-src http://ppa.launchpad.net/linux-phc/ppa/ubuntu jaunty main

beezwings
September 23rd, 2009, 01:38 PM
Yes, they're there. (That's where I had found the 2.6.28-13 ~undervolt files). What did I do wrong?

Ev1L
September 23rd, 2009, 01:45 PM
mmmhhh that's weird, i don't know, maybe you have blocked some kernel version?
(just guessing, i never did it)
or you have commented out some other repository preventing that update?

beezwings
September 23rd, 2009, 01:51 PM
Ok thanks for all the help

EDIT:
Finally got it to work!

After I downloaded and used PHC Tool

From http://aldeby.org/blog/index.php/linux-phc-cpu-undervolting.html:

"There is no package, you have to download a subversion snapshot via:

sudo apt-get install subversion

svn co http://phctool.googlecode.com/svn/trunk/ phctool

The tool has a Analysis tab as you can see in the screenshot.

To get this to work, you first need to

sudo modprobe msr"
Asuna--How did you get it to work?

beezwings
September 23rd, 2009, 02:01 PM
Don't know. I don't even know what commenting is! Any way to restart the whole thing? Ie, downgrade, then upgrade? Please post step-by-step, thanks!

Ev1L
September 23rd, 2009, 03:43 PM
from here:
https://launchpad.net/~linux-phc/+archive/ppa

Follow exactly the instructions in the link "Read about installing"
Especially the part adding the key to authenticate the repository

beezwings
September 23rd, 2009, 11:10 PM
I had already done that. I followed the exact steps again anyway. Still, there's no sign of a 2.6.28-15 ~undervolt kernel. Looks like someone else in this forum had the problem of downloading the 2.6.28.13 ~undervolt kernel, but the system wasn't recognizing it to be undervolted. Don't know how she fixed it though.

Ev1L
September 24th, 2009, 03:39 AM
i am sorry but i wouldn't know what else to try without having the machine in my hands.
from synaptic you can't see 2.6.28.15 installable/upgradable?
when i added the repository here, i could see such kernel to upgrade but i can't remember if it was clear it was the undervolt one if not looking at the properties of the package or doing uname -a after installing it

beezwings
September 24th, 2009, 09:09 AM
No, there isn't anything to upgrade...the only versions of 2.6.28.15 is the one I currently have (not the ~undervolt). Too bad.

winnibob
September 24th, 2009, 09:51 AM
Not solved yet...I couldn't find anything with 2.6.28-15 ~undervolt in the repositories, so I tried installing 2.6.28-13 ~undervolt a few days ago. Now I have some strange mix. What is installed is the following:


linux-headers-2.6.28-13 ~undervolt5
linux-headers-2.6.28-13-generic ~undervolt5
linux-image-2.6.28-13-generic ~undervolt5
linux-image-2.6.28-15-generic
linux-image-generic (version 2.6.28-15.20)

Could you tell us where you found the packages for 2.6.28-13~undervolt5 , since I can't find them any more on the ppa? Did you just update the kernel via update-manager or synaptics, or did you get these packages from somewhere else?
Anyway, you could try undervolting with this older kernel, choosing it at startup in grub.

If you can't connect to linux-phc's ppa for updates, you can download udeb packages of the most recent version (i.e. 2.6.28-15.50 for now) here (https://launchpad.net/~linux-phc/+archive/ppa/+packages), but it is not really safe because your system can't check the authenticity of the packages as update-manager do.
The best way to get ~undervolt kernel is to find out why you can't connect to the ppa for updating you current kernel

Uhuu
October 3rd, 2009, 02:17 AM
2.6.28-15 undervolt-kernel was in the ppa few weeks ago, but now synaptic only offers 2.6.28-11 :confused:


EDIT:

downloaded kernel manually from https://launchpad.net/~linux-phc/+archive/ppa/+sourcepub/705101/+listing-archive-extra

now all works

htrex
October 5th, 2009, 03:17 PM
the latest version from jaunty-updates is 2.6.28-15.52 while on https://launchpad.net/~linux-phc/+archive/ppa is 2.6.28-15.50.

I seriously hope Karmic is not shipping with acpi modules compiled into kernel.

(please vote http://brainstorm.ubuntu.com/idea/20847/ if you care about this too)

mister_playboy
October 10th, 2009, 12:25 AM
the latest version from jaunty-updates is 2.6.28-15.52 while on https://launchpad.net/~linux-phc/+archive/ppa is 2.6.28-15.50.

I seriously hope Karmic is not shipping with acpi modules compiled into kernel.

(please vote http://brainstorm.ubuntu.com/idea/20847/ if you care about this too)

I agree. I'm still running 2.6.28-11 since I haven't been able to get undervolting in anything newer.

I won't be moving to 9.10 without undervolting... :(

kevinguillorytraining
October 10th, 2009, 12:44 AM
I followed all of your instructions but my Latitude E6400 battery not increased more than half hour. Is it possible to increase more time?

mister_playboy
October 10th, 2009, 01:03 AM
I followed all of your instructions but my Latitude E6400 battery not increased more than half hour. Is it possible to increase more time?

Generally speaking, lowering the CPU temp is the main advantage of undervolting. It won't increase the battery life too much since the CPU doesn't use much power compared to the screen or hard drive... 30 minutes is probably as good as could be expected.

Uhuu
October 30th, 2009, 07:17 PM
Anybody got this working on Karmic?

tula
November 11th, 2009, 11:28 PM
still not working on karmic koala + turion x2 RM processor ?

zcats
November 26th, 2009, 04:05 PM
Undervolting for 9.10 Karmic was as simple as adding the ppa for PHC and installing the kernel 2.6.31-14-generic-phc using synaptic.
BTW I have a Pentium M processor 1.70GHz and previously had acpi-cpufreq.ko in home (separate partition) before I upgraded to karmic
Of course I still needed to determine and set my optimal values and edit your /etc/rc.local file to make permanent. Add this (using your values):-
echo "17:19 14:12 12:18 10:4 8:1 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
exit 0

The 2.6.31-15-generic-phc is not in the phc ppa yet so I am staying with 2.6.31-14-generic-phc (a bit behind on kernel updates, but thats OK;)

zcats
December 1st, 2009, 02:44 AM
Ermmmm. This is not quite right, sorry!. Please see my other Ubuntu post in
"Undervolting in Karmic on a Pentium M - a Howto".

Use the instructions by Ebsbel and it works on Karmic..:p

zcats
December 1st, 2009, 02:45 AM
see
http://ohioloco.ubuntuforums.org/showthread.php?p=8418342#post8418342

aldeby
January 4th, 2010, 10:22 AM
[QUOTE=asuna;7644198]Ok thanks for all the help
EDIT:
Finally got it to work!

After I downloaded and used PHC Tool

From http://aldeby.org/blog/index.php/linux-phc-cpu-undervolting.html:

Thank you asuna for quoting my post.
Although the actual blog page is http://linux.aldeby.org/linux-phc-cpu-undervolting.html

H.i.M
January 16th, 2010, 12:30 PM
I installed the phc kernel by the ppa:linux-phc/ppa.

uname -r
2.6.31-17-generic-phc



Could someone tell me where the phc_controls-file is gone?
Isnt the phc kernel the right one to undervolt?

ls -a /sys/devices/system/cpu/cpu0/cpufreq/
. affected_cpus cpuinfo_max_freq cpuinfo_transition_latency related_cpus scaling_available_governors scaling_driver scaling_max_freq scaling_setspeed
.. cpuinfo_cur_freq cpuinfo_min_freq ondemand scaling_available_frequencies scaling_cur_freq scaling_governor scaling_min_freq stats


thanks
h.i.m

mister_playboy
January 19th, 2010, 04:44 AM
Honestly, we really need a new thread for this topic. The instruction in the first post don't work for any recent kernel and most people aren't going to dig through this whole thread to find the answer.

Anybody who knows exactly what they are doing want to start a new one? I will admit I'm not the one to do it... ;)

Ares Drake
January 20th, 2010, 03:31 AM
Honestly, we really need a new thread for this topic. The instruction in the first post don't work for any recent kernel and most people aren't going to dig through this whole thread to find the answer.

Anybody who knows exactly what they are doing want to start a new one? I will admit I'm not the one to do it... ;)

Unfortunately I currently find no time at all for updates in this matter.

If you however want the first post changed, either with a link to a new thread or with new, provided information & guidelines I am more than willing to help!

Greetz
Drake

jocko
February 13th, 2010, 03:46 AM
I installed the phc kernel by the ppa:linux-phc/ppa.

uname -r
2.6.31-17-generic-phc

Could someone tell me where the phc_controls-file is gone?
Isnt the phc kernel the right one to undervolt?

ls -a /sys/devices/system/cpu/cpu0/cpufreq/
. affected_cpus cpuinfo_max_freq cpuinfo_transition_latency related_cpus scaling_available_governors scaling_driver scaling_max_freq scaling_setspeed
.. cpuinfo_cur_freq cpuinfo_min_freq ondemand scaling_available_frequencies scaling_cur_freq scaling_governor scaling_min_freq stats
thanks
h.i.m
Any news on this? None of the phc kernels after 2.6.31-14-generic-phc has any phc_controls file. Interesting how the acpi-cpufreq module in the phc kernel seems to be built without phc support... Or have they just changed how it works and forgotten to inform the users?

jocko
February 13th, 2010, 04:36 AM
Any news on this? None of the phc kernels after 2.6.31-14-generic-phc has any phc_controls file. Interesting how the acpi-cpufreq module in the phc kernel seems to be built without phc support... Or have they just changed how it works and forgotten to inform the users?
Found the answer to my own question. Apparently the patched module is no longer included in the phc kernel (why?), so this has to be done by the user...

This is how to get it working with an intel cpu:
1. Boot into the latest phc kernel.
2. Download the linux-phc patch from here (http://www.linux-phc.org/forum/viewtopic.php?f=13&t=2) (get the latest intel "offtree" patch).
3. Unpack the tar.bz2 file.
4. Build and install the patched module (instructions from the included README file):
make prepare
make
sudo make install

5. Reboot into the same kernel.

Note that this was the simple process for the "offtree" patch, which as far as I can see is only available for intel at the moment. The amd patches use dkms to build ad install the module.

Ev1L
February 13th, 2010, 04:56 AM
I can confirm that is the current easiest procedure.

Note that this was the simple process for the "offtree" patch, which as far as I can see is only available for intel at the moment. The amd patches use dkms to build ad install the module.

There are separate instructions for amd somewhere on phc website.
But once you get dkms working, you won't need future compiling at each phc kernel upgrade (as it is for intel offtree).

karunadheera
February 19th, 2010, 10:25 PM
I do not get the file content of "phc_tweaked_vids" as freq:voltage pairs.
It contains only following.

7 7 7 1 1

What should I echo to pch_controls then?

Thanks in advance.

beezwings
March 11th, 2010, 05:18 PM
Hi~

Can someone help? I used to have my laptop undervolted. Since my upgrade to a few days ago to Karmic koala, I get through to all the undervolting steps, but for some reason, when I reboot, the system doesn't seem to be reading the rc.local file, since my values are still the same. When I try either sudo echo "11:22 8:1 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls, I get a "permission denied" message. I'm a newbie, so please walk me through, thanks!

kasjak2000
March 11th, 2010, 05:23 PM
Hi~

Can someone help? I used to have my laptop undervolted. Since my upgrade to a few days ago to Karmic koala, I get through to all the undervolting steps, but for some reason, when I reboot, the system doesn't seem to be reading the rc.local file, since my values are still the same. When I try either sudo echo "11:22 8:1 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls, I get a "permission denied" message. I'm a newbie, so please walk me through, thanks!

Hi,

please try this with help of tee.

echo "11:22 8:1 6:1" | sudo tee /sys/devices/system/cpu/cpu0/cpufreq/phc_controls

and th same for cpu1, if you have one with 2 cores.

beezwings
March 11th, 2010, 06:31 PM
Hi,

please try this with help of tee.

echo "11:22 8:1 6:1" | sudo tee /sys/devices/system/cpu/cpu0/cpufreq/phc_controls

and th same for cpu1, if you have one with 2 cores.

Great, that works for this session, but when I reboot, it still resets. How can I load that for every boot?

Additionally, I have a program called "vaiofand" that I would also like to run at every boot. How would I add that as well?

Thanks!

kasjak2000
March 12th, 2010, 02:15 AM
Great, that works for this session, but when I reboot, it still resets. How can I load that for every boot?

Additionally, I have a program called "vaiofand" that I would also like to run at every boot. How would I add that as well?

Thanks!

Hey cool :)

Ok, please add this 2 lines (if you have one with 2 cores, if you have 1 core, the first line only ) into the /etc/rc.local with sudo vi /etc/rc.local


echo "11:22 8:1 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls

echo "11:22 8:1 6:1" > /sys/devices/system/cpu/cpu1/cpufreq/phc_controls


Now make a reboot and debug the settings with:

cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
and
cat /sys/devices/system/cpu/cpu1/cpufreq/phc_controls

beezwings
March 12th, 2010, 05:36 PM
Hey cool :)

Ok, please add this 2 lines (if you have one with 2 cores, if you have 1 core, the first line only ) into the /etc/rc.local with sudo vi /etc/rc.local


echo "11:22 8:1 6:1" > /sys/devices/system/cpu/cpu0/cpufreq/phc_controls

echo "11:22 8:1 6:1" > /sys/devices/system/cpu/cpu1/cpufreq/phc_controls


Now make a reboot and debug the settings with:

cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
and
cat /sys/devices/system/cpu/cpu1/cpufreq/phc_controls

I had done this previously, but it seems this file is not being read at reboot because when I run the cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls I get my old values and have to sudo tee again manually.

Additionally, how can I run the vaiofand command automatically at startup (requires root).

Thanks!

kasjak2000
March 12th, 2010, 06:08 PM
I had done this previously, but it seems this file is not being read at reboot because when I run the cat /sys/devices/system/cpu/cpu0/cpufreq/phc_controls I get my old values and have to sudo tee again manually.

Additionally, how can I run the vaiofand command automatically at startup (requires root).

Thanks!

Regarding the /etc/rc.local -> it has to end with exit 0 in the last line.

Is it so in your rc.local?

Regarding the autostart of programs, please check .config/autostart/ directory in your home. There are some *.desktop files. Just study some of them.

http://wiki.ubuntuusers.de/autostart

Good luck

beezwings
March 12th, 2010, 07:57 PM
Thanks for the info.

Unfortunatly, I already had exit 0 as the last line of rc.local, so the problem seems to be something else. Any ideas?

kasjak2000
March 16th, 2010, 01:05 PM
Thanks for the info.

Unfortunatly, I already had exit 0 as the last line of rc.local, so the problem seems to be something else. Any ideas?

Please check the output of chkconfig -list

This should be something like that:

rc.local 0:off 1:off 2:on 3:on 4:on 5:on 6:off

Here you can see, that the rc.local starts in runlevels 2, 3, 4 and 5(GUI).

I have a speculation, that your rc.local doesnt start.

best regards
kasjak2000

beezwings
March 16th, 2010, 02:19 PM
Please check the output of chkconfig -list

This should be something like that:

rc.local 0:off 1:off 2:on 3:on 4:on 5:on 6:off

Here you can see, that the rc.local starts in runlevels 2, 3, 4 and 5(GUI).

I have a speculation, that your rc.local doesnt start.

best regards
kasjak2000

That's exactly what it outputs...what to do now?

kasjak2000
March 16th, 2010, 02:35 PM
That's exactly what it outputs...what to do now?

Oh man, sorry, i dont know anymore :(

Colleagues, could you please assist here?

ChaosHead
March 19th, 2010, 09:11 PM
Hi
I am wondering if there is any update on undervolting cpus on amd platform.
Last 4-5 months I was trying to get started with undervolting of my laptops MV-40(amd neo) cpu, but I could not find any guide. All guys/girls are just talking about intel...
Is there actually anyone who undervolts those cpus? Here is my laptop:

http://arstechnica.com/hardware/news/2009/01/amds-neo-processor-debuts-in-hp-notebook-whoah.ars

This is the only thing that holds me back from abadoning windows. :(.

nema.arpit
March 20th, 2010, 01:01 AM
I don't know if it'll work,but try this thread:
http://ubuntuforums.org/showthread.php?t=1433885

ChaosHead
March 20th, 2010, 01:34 AM
Thanks for making a guide specially for me. You are the best ;).
I'll tell all my friends in Norway about great ubuntu-community.
I can finally sit down and get my computer running cool...
It will not be forgotten, may force be with you.

NESFreak
May 6th, 2010, 06:10 PM
Hi, i'm heaving some problems with the optimization script: it forces my laptop into thermal throttling (dell m1330 damn this thing runs hot), resulting in quite unreliable results.

So if by any chance anyone has an intel T8100 could there be any chance of sharing your optimal values with me? On some german forum I've already found the following values 75:27 74:27 8:23 6:19 136:15 and for now it seems to be working quite well.

thanks

(PS. maybe it would be a good idea to make a wiki page of all the processors and their optimal values. Just a thought.)

mihai007
May 8th, 2010, 07:40 PM
Hello.
I created a updated guide for Ubuntu 10.04LTS, with a new script that checks the minimum voltage that works for multi core cpu's.
Take a look at
http://openmindedbrain.info/09/05/2010/undervolting-in-ubuntu-10-04-lucid-lts/

Naaktgeboren
May 12th, 2010, 11:55 AM
beezwings: As regards vaiofand (http://vaio-utils.org/fan/), if you install the Debian package from https://launchpad.net/~vaiofand/+archive/ppa, it will be started automatically upon boot.

zcats
June 1st, 2010, 01:05 PM
:guitar::guitar::guitar::guitar
LOOK here
http://openmindedbrain.info/09/05/2010/undervolting-in-ubuntu-10-04-lucid-lts/

Instructions copied below....
1. As we are going to use a custom kernel, we need to add the linux-phc PPA repository, so just open a terminal and execute:

1 $ sudo add-apt-repository ppa:linux-phc/ppa
2 $ sudo apt-get update
Basically they provide the same kernel as the Ubuntu one but with the patch that is capable for Undervolting.
2. Next we need to install the phc kernel, with headers:

1 $ sudo apt-get install linux-generic-phc linux-headers-generic-phc
Ok, now we need to restart and use the installed phc kernel when booting. After restarting, you can check if you are using the phc kernel by using

1 $ uname -r
2 2.6.32-21-generic-phc
If no "phc" appears, then you have to configure grub2 to allow you to chose boot options and select the phc kernel at boot time. This can be done many ways one would be:
(This section was NOT necessary for me.... zcats)

1 sudo update-grub
and count the number of lines that says "Found linux image" (first one is 0) and, when you found the phc one, do:

1 sudo gedit /etc/default/grub
then just change the "GRUB_DEFAULT=0" to the number of the entry you found that has phc. Save the file and do a update-grub command again like in the first step. Now you can reboot into the phc kernel.
3. Great, we are using a phc kernel, now we need to add the actual undervolt module, as the kernel comes only with support for it, not the actual module. First download phc-intel offtree module from here. Right now they have "phc-intel-0.3.2-10 offtree" version. Direct link to the tar.bz2 file here. Unpack the files anywhere and point the terminal to the directory where you extracted the files and do:

1 $ make prepare
2 $ make
3 $ sudo make install
Right now you should have the module installed, check if everything worked by typing:

1 $ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
2 40 34 31 27 23 15
If everything worked, you should see some numbers (the ones above are the default ones for my CPU). If not, you may try to restart and check back to see if it works.
4. So right now we are set, the only thing we have to do is... undervolt the CPU.
Now we have to discover the limits of the CPU by lowering it's current voltage one step at a time and set the voltage 4 steps above the critical limit (where the cpu starts to give wrong calculations or the PC simply crashes).

Why four? Well the recommendation was 2 steps above, but with this limit the PC crashed in the same day hours later, so I made it 3 steps, then some days after it crashed again. So I think 4 steps should actually do it. If not, you may increase this value until it suits you.

Ok great now how to find the actual critical limit? There exists a script, created by the community, but it's old and it does not work for multi core CPU's and also in my particular case it sets the voltage directly below this critical limit so the PC crashes instantly.

I updated this script and made it work on multi core CPU's (hopefully it will work for you too), so you just have to download the script, then give it execution permissions and execute it and follow on-screen indications see http://openmindedbrain.info/wp-content/uploads/2010/05/intel-phc-undervolt.bash:

1 $ chmod +x intel-phc-undervolt.bash
2 $ ./intel-phc-undervolt.bash
Oh and make sure you close as many applications as possible when executing the script as the system may actually turn instable (it is intended actually) just to prevent any data loss. The script treats all CPU's cores with the same voltages, so if one of them is weaker than the other (does not support such a aggressive undervolting) is this the critical value that the script uses for all of the others, even if they could possibly use a even lower value.
5. After you finished with the script, now you should have a "phc_tweaked_vids" file, containing the acceptable steps for your CPU. Now you only have to make changes permanent (load them at every boot of the pc) by editing /etc/rc.local file:

1 $ sudo gedit /etc/rc.local
and adding one entry for every core you have, something like:

1 echo "23 20 4 4 4 4" > /sys/devices/system/cpu/cpu0/cpufreq/phc_vids
2 echo "23 20 4 4 4 4" > /sys/devices/system/cpu/cpu1/cpufreq/phc_vids

just before the "exit 0". Note that "23 20 4 4 4 4" are my values, you have to replace the above with your values, that came from the "phc_tweaked_vids" file. So that's about it. Not too easy, not too complicated.

So... is it worth it? I have done some tests to see if the above actually works as said, so first I tested to see if on battery using powertop application and the CPU temperature I could see any differences. None actually, if the CPU is in idle state, there is no actual gain using undervolting, be it battery or temperature.

But when I've done the test under full load (using 2 burnMMX instances, one for every core) and with the CPU set at it's maximum 2.4Ghz I could see a very very noticeable difference.

see website for data of temp and energy (W) saved:):):)

Vladimir_S
June 28th, 2010, 10:36 AM
Please, who can tell me, what is wrong?

vladimir@vladimir-laptop:~/Downloads/phc-intel-0.3.2-10$ make prepare
FOUND AVAILABLE PATCHSET. PREPARING.
patching file phc-intel.c
vladimir@vladimir-laptop:~/Downloads/phc-intel-0.3.2-10$ make
make -C /lib/modules/`uname -r`/build SUBDIRS=/home/vladimir/Downloads/phc-intel-0.3.2-10 modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.32-22-generic-phc'
CC [M] /home/vladimir/Downloads/phc-intel-0.3.2-10/phc-intel.o
Building modules, stage 2.
MODPOST 1 modules
CC /home/vladimir/Downloads/phc-intel-0.3.2-10/phc-intel.mod.o
LD [M] /home/vladimir/Downloads/phc-intel-0.3.2-10/phc-intel.ko
make[1]: Leaving directory `/usr/src/linux-headers-2.6.32-22-generic-phc'
vladimir@vladimir-laptop:~/Downloads/phc-intel-0.3.2-10$ sudo make install
install -m 644 -o root -g root phc-intel.modprobe /etc/modprobe.d/phc-intel.conf
mkdir -p /lib/modules/2.6.32.11+drm33.2/extra
install -m 644 -o root -g root phc-intel.ko /lib/modules/2.6.32.11+drm33.2/extra/
depmod 2.6.32.11+drm33.2 -a
vladimir@vladimir-laptop:~/Downloads/phc-intel-0.3.2-10$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
cat: /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids: No such file or directory
vladimir@vladimir-laptop:~/Downloads/phc-intel-0.3.2-10$


Ubuntu 10.04. My CPU is Core2Duo T5600 (Mobile) And i used manual in previous post by zcats(#481)

Thank You!

nicocarbone
August 2nd, 2010, 11:07 PM
I am having the same problem that Vladimir_S. I am using a Core 2 Duo T5550 laptop on Ubuntu 10.4 amd64.

Any ideas??

jocko
August 3rd, 2010, 02:34 AM
Please, who can tell me, what is wrong?

vladimir@vladimir-laptop:~/Downloads/phc-intel-0.3.2-10$ make prepare
FOUND AVAILABLE PATCHSET. PREPARING.
patching file phc-intel.c
vladimir@vladimir-laptop:~/Downloads/phc-intel-0.3.2-10$ make
make -C /lib/modules/`uname -r`/build SUBDIRS=/home/vladimir/Downloads/phc-intel-0.3.2-10 modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.32-22-generic-phc'
CC [M] /home/vladimir/Downloads/phc-intel-0.3.2-10/phc-intel.o
Building modules, stage 2.
MODPOST 1 modules
CC /home/vladimir/Downloads/phc-intel-0.3.2-10/phc-intel.mod.o
LD [M] /home/vladimir/Downloads/phc-intel-0.3.2-10/phc-intel.ko
make[1]: Leaving directory `/usr/src/linux-headers-2.6.32-22-generic-phc'
vladimir@vladimir-laptop:~/Downloads/phc-intel-0.3.2-10$ sudo make install
install -m 644 -o root -g root phc-intel.modprobe /etc/modprobe.d/phc-intel.conf
mkdir -p /lib/modules/2.6.32.11+drm33.2/extra
install -m 644 -o root -g root phc-intel.ko /lib/modules/2.6.32.11+drm33.2/extra/
depmod 2.6.32.11+drm33.2 -a
vladimir@vladimir-laptop:~/Downloads/phc-intel-0.3.2-10$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
cat: /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids: No such file or directory
vladimir@vladimir-laptop:~/Downloads/phc-intel-0.3.2-10$
Ubuntu 10.04. My CPU is Core2Duo T5600 (Mobile) And i used manual in previous post by zcats(#481)

Thank You!

I am having the same problem that Vladimir_S. I am using a Core 2 Duo T5550 laptop on Ubuntu 10.4 amd64.

Any ideas??

You need to reboot.

nicocarbone
August 3rd, 2010, 10:31 AM
The problem cannot be solved by rebooting (is the first thing I tried), but I found the solution.

The problem is related to a bug in the phc modified kernel 2.6.32-24-generic-pch. The file utsrelease.h, located in "/usr/src/linux-headers-2.6.32-24-generic-phc/include/linux" is used by the install script oh the intel-phc module to locate the kernel in use, but the string UTS_RELEASE is badly defined (http://www.linux-phc.org/forum/viewtopic.php?f=9&t=211) Where it says "2.6.32.15+drm33.5", it should say "2.6.32-24-generic-phc".

Changing this line, and the repeating the install process, I could load the intel-phc module and I successfully undervolted my CPU. Now it uses 10w less under load and the temperatures are around 10-15C lower.

nicocarbone
August 3rd, 2010, 10:52 AM
Another question: Will it be necessary to repeat all the installation/undervolt process every time Ubuntu releases a new kernel?

Sorry If this was explained before, I couldn't read the 49 pages.

nicocarbone
August 3rd, 2010, 01:46 PM
Me again, with another question:
Everytime I suspend/resume the laptop, the volts are restored to defaults (at least I think this is what happens, because the watts used under load increase after a suspend/resume cycle). Is there a way to avoid this?

Thanks

phazixc
August 4th, 2010, 08:46 AM
I'm Running:-

Toshiba q505 888

Ubuntu 10.04 lucid 64Bit

Core 7i q740
Nvidia Gts 360m 1gb
4 Gb Ram


I Updated to 256.35 = Excellent / perfect

Then my updates from X-swat and Xorg Egders updated to 256.44 this = my world falling apart.

My system completely locks up / hags / kills its self within 4 mins of logging in.

If I load anything I.E wine to run a game.

It really doesnt like that... My problem is i'm only a year into ubuntu and I have done manual updates before, but what im doing isnt working as I have tried purge remove nvidia .44 and disabling the two ppa's then manually installing .35 ..

BUT

when I start the gdm = great it works, then when I restart = not great....because I'm on failsafe graphics and the x sever setting not in menu (if it is in menu then theres nothing in there; apart from that msg to restart X) and when I load Hardware drivers the nvidia card isnt there..

I would like to think that some of your reading this are laughing because you are what I would call a pro in the ubuntu area and that you could / will post a detailed step by step to help me install .35 through the x-swat or x-org egder ppa or even manually download it and install it that way, so when I restart it works, and more to the point I can keep those two ppa's in my system so when i hit the update button I can see ubuntu wants to update to .44 which I WONT DO....

One year into ubuntu and I haven't logged into windows since.

As I find theres always someone will to help fix something in ubuntu..

anyway thats that, Mr/Mrs pro.... can you post that guide please.

P.S im currently on Linux-x86_64 NVIDIA Driver Version: 195.36.24 Server Version Number: 11.0 and Server Vendor Version: 1.8.2 NV-CONTROL Version: 1.22
gnome 2.30.2 and kernel linux 2.6.32-24 generic
platform X86_64



Thanks

nicocarbone
August 4th, 2010, 09:45 AM
phazixc:

I would like to help you, but I have no experience in Nvidia drivers under Ubuntu. I would suggest you to purge the ppa, but you already did this, so I am out of ideas.

What I suggest you is to open a new thread posting you problem, because it is completely off-topic here. Posting a new topic (in Absolute Beginner Talk, or maybe one of the Main Support Categories, like Multimedia and Video) will surely make it viewable to more people, and I am sure someone with the required experience in Nvidia drivers will help you.

phazixc
August 4th, 2010, 12:38 PM
yeap no problem, i thought i posted this in a different form, sorry and thanks anyway.

lemino
November 22nd, 2010, 08:55 AM
Great info, allthough it didn't do the trick for me. Everything seems to be ok: i changed the file so that it pointed to the right kernel, saved, repeated the install process whithout any errors, everything looked right. But when I try to do

cat sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids

it says that it can't find that file, and it's right, the folder "cpufreq" doesn't exist in cpu0. It does exist in "cpu" however, but is empty.

What can be done about this?

/Erik

Docet
March 4th, 2011, 02:16 PM
I found a new guide that also includes the graphiocal tool to set VIDs... take a look here!

http://linuxsolver.blogspot.com/2011/02/undervolting-cpu-in-ubuntu.htmlCheers!

ursoouindio
March 10th, 2011, 10:50 PM
Hi.

I'm having troubles to follow the steps on this guide: http://openmindedbrain.info/09/05/2010/undervolting-in-ubuntu-10-04-lucid-lts/


I manage to get to step 2 ok:
$ uname -r
2.6.32-29-generic-phc

But on step 3 i get:
(I've used the tar.bz2 file (http://www.linux-phc.org/forum/download/file.php?id=87&sid=b05ae625e9678a0efa00fa1d72631d68) suggested on the how-to)
$ sudo make prepare
[sudo] password for marco:
FOUND AVAILABLE PATCHSET. PREPARING.
patching file phc-intel.c

$ sudo make
make -C /lib/modules/`uname -r`/build SUBDIRS= modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.32-29-generic-phc'
CHK include/linux/version.h
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-x86
make[2]: *** No rule to make target `kernel/bounds.c', needed by `kernel/bounds.s'. Stop.
make[1]: *** [prepare0] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-2.6.32-29-generic-phc'
make: *** [phc-intel.ko] Error 2

$sudo make install
make -C /lib/modules/`uname -r`/build SUBDIRS= modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.32-29-generic-phc'
CHK include/linux/version.h
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-x86
make[2]: *** No rule to make target `kernel/bounds.c', needed by `kernel/bounds.s'. Stop.
make[1]: *** [prepare0] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-2.6.32-29-generic-phc'
make: *** [phc-intel.ko] Error 2

So please help me as my notebook is getting too hot even after a good cleanup. And I don't know much about those kernel errors :/


well.. I think I figured it out. Just comparing with other how-to suddenly it worked. Thanks anyway.

ursoouindio
March 22nd, 2011, 09:42 AM
I have undervolted my processor, it is now cooler and quieter :)

But, I noticed I'm still getting the 'normal' kernel updates and compiling them. Just after a while I download the phc version.

As new kernels are released all the time, it seems that I get half the time without the undervolting on my notebook.

How to disable the 'normal' kernel upgdates and leave just the customized phc one?

Thanks

Axa-Ru
August 15th, 2011, 02:15 AM
Hi.
Laptop: Lenovo Thinkpad x220
CPU: i7-2620M
$ cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 42
model name : Intel(R) Core(TM) i7-2620M CPU @ 2.70GHz
stepping : 7
cpu MHz : 800.000
cache size : 4096 KB
physical id : 0
siblings : 4
core id : 0
cpu cores : 2
apicid : 0
initial apicid : 0
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 13
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx rdtscp lm constant_tsc arch_perfmon pebs bts xtopology nonstop_tsc aperfmperf pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 cx16 xtpr pdcm sse4_1 sse4_2 x2apic popcnt xsave avx lahf_lm ida arat epb xsaveopt pln pts dts tpr_shadow vnmi flexpriority ept vpid
bogomips : 5381.84
clflush size : 64
cache_alignment : 64
address sizes : 36 bits physical, 48 bits virtual
power management:


I downloaded and installed the kernel
$ uname -r
2.6.38-8-generic-pae-phc I downloaded from here http://aur.archlinux.org/packages.php?ID=24980 phc-intel-pack-rev2.tar.bz2 (http://www.linux-phc.org/forum/download/file.php?id=127), compiled and instlled the phc module:
$ lsmod | grep phc
phc_intel 17942 1
mperf 12603 1 phc_intel
After reboot i have this:
$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_version
0.3.2:2
$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_fids
34 27 24 22 20 18 16 14 12 10 8
$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
0 0 0 0 0 0 0 0 0 0 0
$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_vids
0 0 0 0 0 0 0 0 0 0 0
$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_default_controls
34:0 27:0 24:0 22:0 20:0 18:0 16:0 14:0 12:0 10:0 8:0
Where did I go wrong?
Thanks in advance,
Alex.


Update .
Compile with "make brave"

$ ls /sys/devices/system/cpu/cpu0/cpufreq/phc_*
/sys/devices/system/cpu/cpu0/cpufreq/phc_default_rawcontrols
/sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
/sys/devices/system/cpu/cpu0/cpufreq/phc_rawcontrols
/sys/devices/system/cpu/cpu0/cpufreq/phc_version
/sys/devices/system/cpu/cpu0/cpufreq/phc_vids
$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_default_rawcontrols
00002200 00001b00 00001800 00001600 00001400 00001200 00001000 00000e00 00000c00 00000a00 00000800
$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
0 0 0 0 0 0 0 0 0 0 0
$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_rawcontrols
00002200 00001b00 00001800 00001600 00001400 00001200 00001000 00000e00 00000c00 00000a00 00000800
$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_version
0.3.199-2
$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_vids
0 0 0 0 0 0 0 0 0 0 0

ShamoIdol
December 31st, 2011, 01:09 PM
Hi.
Laptop: Lenovo Thinkpad x220

$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
0 0 0 0 0 0 0 0 0 0 0
$ cat /sys/devices/system/cpu/cpu0/cpufreq/phc_vids
0 0 0 0 0 0 0 0 0 0 0


I have exactly the same ThinkPad and the same problem. Googling gives only the same reports with X220.

ShamoIdol
January 1st, 2012, 07:37 AM
Also you might be interested in what I've found so far.

1. Undervolting of i7 2620m seems to be not possible. Or at least so far I'm not able to find a solution.
2. Install liqourix kernel, boot with "i915.i915_enable_rc6=1" and do not use any other power-related options including pcie_aspm and you'll get around 5.6 Watt in pure iddle (no radio, min backlight, no Xorg) and around 7-9 in Desktop iddle.

Read this for more info:
http://liquorix.net/

Works like a sharm in Kubuntu oneiric.

drklunk
January 4th, 2012, 06:55 PM
Im in the process of undervolting my CPU in 10.04 LTS using this guide: http://openmindedbrain.info/09/05/20...-04-lucid-lts/

my uname -r returned 2.6.32-37, no -phc, so I needed to go into gedit to change "GRUB_DEFAULT=0" to the corresponding line's number. my question is do I count only the "linux image" lines or also the "initrd image" lines?

update-grub returned

Generating grub.cfg ...
Found linux image: /boot/vmlinuz-2.6.32-37-generic
Found initrd image: /boot/initrd.img-2.6.32-37-generic
Found linux image: /boot/vmlinuz-2.6.32-36-generic
Found initrd image: /boot/initrd.img-2.6.32-36-generic
Found linux image: /boot/vmlinuz-2.6.32-33-generic-phc
Found initrd image: /boot/initrd.img-2.6.32-33-generic-phc
Found linux image: /boot/vmlinuz-2.6.32-33-generic
Found initrd image: /boot/initrd.img-2.6.32-33-generic
Found memtest86+ image: /boot/memtest86+.bin
done

I tried switching "GRUB_DEFAULT" to 2 as well as 4, then ran uname -r again after saving both times and it returned 2.6.32-37 as it did before.

Ares Drake
January 5th, 2012, 10:37 AM
my uname -r returned 2.6.32-37, no -phc, so I needed to go into gedit to change "GRUB_DEFAULT=0" to the corresponding line's number. my question is do I count only the "linux image" lines or also the "initrd image" lines?


Grub counts the titles. First title is 0, second one is 1 and so on.

drklunk
January 5th, 2012, 09:19 PM
Grub counts the titles. First title is 0, second one is 1 and so on.

thanks man, Ill give it another go