LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 03-13-2006, 08:54 PM   #1
-=Graz=-
Member
 
Registered: Jan 2006
Location: Australia
Distribution: Fedora, Slackware, RHEL, AIX, HP-UX
Posts: 358

Rep: Reputation: 31
How to use Cpufreqd - Intel pentium M - kernel.2.6.15


HI all,

I am having problem with do a manual freq set or using CPUSpeedy to do so for me.
I receive error: cpuspeedy: error: ERROR_NO_INTERFACE
Am using Slackware10.1 with kernel 2.6.15
I have SYSFS mounted as /SYS and ACPI/APM enabled.
I am using 'userspace' as the default governor and but also have the 'performance' governor selected.
I chose the 'ondemand' poliy governor for use with the 'userspace;

I chose the Intel Enhanced Speedstep CPUFreq driver with i also included ACPI tables to use for freq/voltage changes.

When i boot the machine with AC it clocks at a lovely 1798mhz
when on battery it runs at 598mhz - which is the same in windows...

I was hoping to be able to either manually set the freq to say 800-900mhz or when using the 'ondemand' governor it would set the freq on the fly (maybe between 600 and 1800 mhz? ) ??

When i try a command like cpuspeedy -s (for status) it says Error No Internface

If i try cat /proc/cpuinfo it reports CPU0 i running at xx clock speed??
i have a feeling that this has something to do with the fact that when i go into: /sys/devices/system/cpu/cpu0 - there is nothing in there?

what have i done wrong?
In KDE i can do manual CPU throttles (which work) - No point when my machine is already running at a mere 600Mhz

On a DELL - 700m/1.8Ghz Centrino/2MBCache
 
Old 03-14-2006, 01:50 PM   #2
raska
Member
 
Registered: Aug 2004
Location: Aguascalientes, AGS. Mexico.
Distribution: Slackware 13.0 kernel 2.6.29.6
Posts: 816

Rep: Reputation: 31
when configuring the kernel, include built-in everything regarding cpufreq for your processor, also the governors and such things.

that works for me.
 
Old 03-14-2006, 05:11 PM   #3
folkenfanel
Member
 
Registered: Sep 2004
Location: formerly Fanelia and Zaibach
Distribution: Slackware-current !
Posts: 342

Rep: Reputation: 59
conservative

Hi

I used to use ondemand, until I realized that "conservative" works great and saves a bit more power. I use it. It depends on you, however.

I think you don't need any userspace application to change your CPU's speed (at least when using "ondemand", the system calculates the right CPU speed on demand...)

Good luck!
 
Old 03-14-2006, 06:30 PM   #4
SqdnGuns
Senior Member
 
Registered: Aug 2005
Location: Pensacola, FL
Distribution: Slackware64® Current & Arch
Posts: 1,092

Rep: Reputation: 174Reputation: 174
I have it all compiled into my kernel, 2.6.14.4

This is what I use to get it all working on my Inspiron 600m. I don't recall where I got this info as I had saved it awhile back.

Code:
Intel Speedstep
As for the cpufreq settings they obviously differ according to what kind of hardware you have, but you need to compile in[*] CPU frequency scaling at the very least, and I also recommend getting CPU Frequency translation statistics.
As for the governors, I have added powersave, userspace and ondemand. The last one, "ondemand", is the one I use, and with great success I might add.

In order for this to work you also need to include the correct CPUfreq processor driver. I've got a Centrino laptop, and thus I compiled in Intel Enhanced Speedstep.

As for the second part of your question, you need to decide if you want to decide the CPU frequency in userspace or in kernelspace. I (without remembering exactly why) started off with doing it in kernelspace, and since it works well, I've stuck with it. Thus I use the "ondemand" governor as I compiled in above. For future freedom of choice I left the other (userspace and powersave) in.

In order to change scaling governor and other ACPI-related settings (CPU speed etc), go to /sys/devices/system/cpu/cpu0/cpufreq directory and echo -n "ondemand" > scaling_governor.

In my rc.local I have added this to do it automatically when my system boots:

if [ -f /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor ]; then
echo -n "Setting Scaling Governor : "
echo -n ondemand > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "ondemand"
fi

Alternatively you can do it in userspace, and find a power daemon called powernowd (google is your friend). It's also a great product, but like I said, I came to like the kernel taking care of it and since it works I stick with it.

This controls my CPU frequency and in turn controls the fan, so my system is nice and cool and gets the job done. Hope this helps, even though it might be slightly on the side of your initial problem.
 
Old 03-14-2006, 11:10 PM   #5
-=Graz=-
Member
 
Registered: Jan 2006
Location: Australia
Distribution: Fedora, Slackware, RHEL, AIX, HP-UX
Posts: 358

Original Poster
Rep: Reputation: 31
Thanks all!
I am at work at the moment but will check out all your posts when i return home..

Thanks!
 
Old 03-15-2006, 02:07 AM   #6
Mr_C
Member
 
Registered: Jan 2004
Location: Trinidad & Tobago
Distribution: Slackware
Posts: 317

Rep: Reputation: 30
this is what I use

Code:
(clay@lib09:pts/1)(~)
(%) tail /etc/rc.d/rc.M 
  . /etc/rc.d/rc.local
fi

# Power Profile I have designated
if [ -x /etc/rc.d/rc.loadmypower ]; then
  . /etc/rc.d/rc.loadmypower
fi


# All done.
(clay@lib09:pts/1)(~)
(%) cat /etc/rc.d/rc.loadmypower 
#!/bin/bash
#

echo "powersave" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
(clay@lib09:pts/1)(~)
(%)

Last edited by Mr_C; 03-15-2006 at 02:09 AM.
 
Old 03-16-2006, 11:58 PM   #7
-=Graz=-
Member
 
Registered: Jan 2006
Location: Australia
Distribution: Fedora, Slackware, RHEL, AIX, HP-UX
Posts: 358

Original Poster
Rep: Reputation: 31
Hey sqndGuns.. thanks for the info..

From memory if i go to /sys/devices/system/cpu/cpu0 there is actually nothing in there?
i wonder why this is?... seems like somthing is wrong there to start with

I also have a centrino laptop (almost the same as yours but 12.1inch display)
I think i will go with the kernel space option as well - sounds like it works well...
I do have one question though... Does the machine runn at say 500mhz on battery and then 1.5ghz on AC prior to setting up the cpufreq?
since configuring cpufreq in kernel space does the machine have the capability of upping to faster than 500mhz on battery? say 600 or 700mhz etc?

I wanted to run the userspace option so as i could force it to about 7-800mhz ... but it the kernel will decide what i need (and has the ability to push it past 600mhz) then i will do that..

When my machine boots on AC it is 1.8ghz and 600mhz on battery... Im not sure if this is a hardware setting of some kind though ...

i think id better look at my .config and double check all my settings again
 
Old 03-17-2006, 12:39 AM   #8
Mr_C
Member
 
Registered: Jan 2004
Location: Trinidad & Tobago
Distribution: Slackware
Posts: 317

Rep: Reputation: 30
You don't have anyting cause you have to compile cpu state throthling in as enabled <well you could use module but thats more overhead loading the modules now> in your kernel config under ACPI.

You shouldn't use userspace cause its a real drain. Most users recognise this after a while.

Well, a long long time ago when my notebook was brand new and the battery had some real purpose, it ran at its lowest clock speed: 538 but when I pluggedin my ac, it shot back up to 1.8G. Plus I got blinded by the bright screen. I was using ondemand.
 
Old 03-18-2006, 05:42 PM   #9
-=Graz=-
Member
 
Registered: Jan 2006
Location: Australia
Distribution: Fedora, Slackware, RHEL, AIX, HP-UX
Posts: 358

Original Poster
Rep: Reputation: 31
well after re-compiling my kernel again and have fixed a whole bunch of things actually.
Now i have the cpu throttling enabled. I chose all the governors and picked userspace as the default.-ondemand as the default.

Now on battery it runs at 600Mhz and on AC @ 1.8 Ghz (same as before)
when booting on battery i can type cpuspeedy 800 mhz and it will up the clock rate accordignly.. exactly what i wanted!

I am not sure how to switch between governors properly? If i do it in KDE Xwindows it reports something strange. if i pick 'OnDemand' then CPUSPeedy reports that it is at 1.8 ghz on battery...
I would have thought it would drop it back to the 600mhz an then 'increase/ on demand'

anyhow. Also fixed up the frame buffer problem i was having (No penguin and had to use vga = normal in lilo.conf
This was done by stepping outside of Xconfig and using menuconfig when building the .config file...
When in xconfig i did not get the option to choose 'VESA frame' ? strange..

Anyway, everything is working as i wanted it to - more overhead with userspace or not.. im happy
i like the idea of manual cpufreq sets and ths compile i have gained a whole deal as i found a couple of other settings which woul dhave caused system latency..

this rocket ship cranks!

THanks all!

Dell700m@slackware10.1 / 1.8Ghz PM/ 80GB 5400rpm/ 1024MB DDR/ DVDRW-DL/ 12.1"Wscreen/ 5 hour battery
 
Old 03-20-2006, 09:24 AM   #10
raska
Member
 
Registered: Aug 2004
Location: Aguascalientes, AGS. Mexico.
Distribution: Slackware 13.0 kernel 2.6.29.6
Posts: 816

Rep: Reputation: 31
Quote:
Originally Posted by -=Graz=-
I am not sure how to switch between governors properly
check cpudyn out. I use it in combination with cpuspeedy
 
Old 03-23-2006, 09:17 AM   #11
-=Graz=-
Member
 
Registered: Jan 2006
Location: Australia
Distribution: Fedora, Slackware, RHEL, AIX, HP-UX
Posts: 358

Original Poster
Rep: Reputation: 31
So does the /etc/cpufreqd.conf file still get referenced if you are using the ondemand governor?
when i use echo "ondemand" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor - it looks like it does the trick (cpu freq reported in /proc/cpuinfo is 598mhz) and a new directory is created in /sys/devices/system/cpu/cpu0/cpufreq called '/ondemand' and i can see all the different states in there...
But how does the cpufreq.conf reference this... ?
All the entries in my .conf file relate to the performance governor (looks exact same as example in man cpufreqd)

so when enabling ondemand is the only thing to do to start it..? Or do i need to change the entries in the .conf file to use ondemand?
so you guys have your machines running ondemand even when plugged into AC?
 
Old 03-23-2006, 06:29 PM   #12
-=Graz=-
Member
 
Registered: Jan 2006
Location: Australia
Distribution: Fedora, Slackware, RHEL, AIX, HP-UX
Posts: 358

Original Poster
Rep: Reputation: 31
Quote:
Originally Posted by -=Graz=-
So does the /etc/cpufreqd.conf file still get referenced if you are using the ondemand governor?
when i use echo "ondemand" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor - it looks like it does the trick (cpu freq reported in /proc/cpuinfo is 598mhz) and a new directory is created in /sys/devices/system/cpu/cpu0/cpufreq called '/ondemand' and i can see all the different states in there...
But how does the cpufreq.conf reference this... ?
All the entries in my .conf file relate to the performance governor (looks exact same as example in man cpufreqd)

so when enabling ondemand is the only thing to do to start it..? Or do i need to change the entries in the .conf file to use ondemand?
so you guys have your machines running ondemand even when plugged into AC?
Okay - so i have found a great way to test the ondemand governor - works really well!
Im Glad i went for this now. laptop does seem to run cooler now as well and on batteries its nice to be @ 1.8ghz for a couple of seconds when needed.

watch grep \"cpu MHz\" /proc/cpuinfo
If i then set this window to be ontop of all other windows i can launch a bunch of apps and see what happens
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Intel Pentium 640+ processor (LGA775) recognized as two prcessors? victorh Linux - Hardware 6 04-22-2006 03:17 AM
getting an optimum OS for my intel pentium 3 750 MHz ,128 mb ram computer shyamsundar Linux - Newbie 10 02-05-2006 02:34 AM
Intel Pentium 4 Temperature marcusshirley Linux - Hardware 2 01-22-2006 04:08 PM
Intel Celeron and Pentium Ds with 64bit Linux RedShirt Linux - Distributions 4 11-24-2005 05:10 PM
Intel Pentium D and Linux soulwatcher1974 Linux - Hardware 1 11-11-2005 03:35 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 03:41 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration