Change font size
It is currently Sun 5. Sep 2010, 16:30


Post a new topicPost a reply Page 1 of 1   [ 3 posts ]
Author Message
 Post subject: Can't set vids by hand but phctools can.
PostPosted: Sat 17. Jul 2010, 08:03 

Joined: Sun 15. Nov 2009, 19:41
Posts: 4
I've used PHC successfully under Ubuntu 9.04 with my Thinkpad x200. I recently installed 10.04 and am unable to change the phc_default_vids manually. But when I run PHCtool, they get set. How does PHCtool set the vid values? Below is what I tried, I even added the owner write bit as a test. I also tried setting via /etc/sysfs.conf, which didn't work either.

Code:
root@light:~/# cat  /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
43 35 23 17
root@light:~/# echo "21 20 17 17" | sudo tee  /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
tee: /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids: Permission denied
21 20 17 17
[code]root@light:~/# cat  /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
43 35 23 17
root@light:~/# chmod u+w  /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
root@light:~/# echo "21 20 17 17" | sudo tee  /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
tee: /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids: Input/output error
[code]root@light:~/# cat  /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
43 35 23 17

Any ideas what I can do differently (or how phctools does it) so I can get these values set at boot automatically?

EDIT: posted in phctools since it works with this software and someone who knows pchtool may have a good chance of solving. Feel free to move to PHC if appropriate.


Top
 Profile  
 
 Post subject: Re: Can't set vids by hand but phctools can.
PostPosted: Sat 17. Jul 2010, 16:43 
User avatar

Joined: Fri 18. Jul 2008, 11:25
Posts: 104
You cannot change the default values, they are only there for reference, e.g. for undoing:
Code:
cat phc_default_vids|sudo tee phc_vids

The "phc_default_vids" isn't something you can set, they are hardcoded in either the processor, the ACPI definition and/or the BIOS.

_________________
A bank is a place where they lend you an umbrella in fair weather and ask for it back when it begins to rain -- R. Frost


Top
 Profile  
 
 Post subject: Re: Can't set vids by hand but phctools can.
PostPosted: Sun 29. Aug 2010, 12:50 

Joined: Sun 15. Nov 2009, 19:41
Posts: 4
Yes, this was the issue. However, in Ubuntu 10.04, I've found that I can't set the values in sysfs.conf, it seems they are being overwritten with the defaults later. Instead of trying to figure out if there is a way around this, I simply made a script /etc/init.d/set-vids which I linked to /etc/rc.2/S99set-vids so that it gets called at the end of startup. Nothing complex, but in case it helps anyone else to see what I did, here it is.
  • Alter the for statement based on your number of cores
  • Alter the VIDS variable based on the voltage your processor will run at. (this assumes that all cores have same VID limits

Code:
#! /bin/bash

VIDS="22 22 17 17"

for i in {0..1}
  do   
    FILE="/sys/devices/system/cpu/cpu$i/cpufreq/phc_vids"
    echo $VIDS > $FILE
    echo $FILE
    cat $FILE
  done
echo "VIDS set"


Top
 Profile  
 
Display posts from previous:  Sort by  
Post a new topicPost a reply Page 1 of 1   [ 3 posts ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron


Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
610nm Style by Daniel St. Jules of Gamexe.net