Kernel 3.13 on Pentium M with PHC rev.14 - no worky?

If you have trouble with PHC you can ask and hope for help here.
Post Reply
Bluubekt
Posts: 9
Joined: Tue 22. Nov 2011, 17:32

Kernel 3.13 on Pentium M with PHC rev.14 - no worky?

Post by Bluubekt » Wed 23. Apr 2014, 00:11

I'm having some trouble getting PHC-Intel to work on an old (but surprisingly usable!) Thinkpad X32 with a Pentium M 755 (Centrino/Dothan). I have downloaded phc-intel-pack-rev14 which builds and installs without any errors - though I do get a warning, which I think is ok to ignore?

Code: Select all

phc-intel.c:256:3: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
   u32 fid;
After building and installing I added the boot param to /etc/default/grub:

Code: Select all

GRUB_CMDLINE_LINUX="cpufreq_driver=phc-intel"
Then I ran update-grub2 and rebooted, and phc-intel appears to load as the cpufreq driver:

Code: Select all

$ lsmod | grep phc
phc_intel              20069  1 
I'm assuming there is no need to remove/blacklist acpi-cpufreq in addition to this, but for the record I still get the following:

Code: Select all

$ sudo modprobe -r acpi-cpufreq
modprobe: FATAL: Module cpufreq_stats is builtin.
So far so good, now for the problem: all the phc_* files in /sys/devices/system/cpu/cpu0/cpufreq/ apart from phc_version are null files and I can't change the voltages with any of the tools/scripts I've tried.

Code: Select all

ls -la /sys/devices/system/cpu/cpu0/cpufreq/
total 0
drwxr-xr-x 3 root root    0 Apr 22 14:53 .
drwxr-xr-x 7 root root    0 Apr 22 14:51 ..
-r--r--r-- 1 root root 4096 Apr 22 15:14 affected_cpus
-r--r--r-- 1 root root 4096 Apr 22 15:14 bios_limit
-r--r--r-- 1 root root 4096 Apr 22 15:14 cpuinfo_max_freq
-r--r--r-- 1 root root 4096 Apr 22 15:14 cpuinfo_min_freq
-r--r--r-- 1 root root 4096 Apr 22 15:14 cpuinfo_transition_latency
-r--r--r-- 1 root root 4096 Apr 22 15:14 freqdomain_cpus
-rw-r--r-- 1 root root 4096 Apr 22 15:14 phc_controls
-r--r--r-- 1 root root 4096 Apr 22 15:14 phc_default_controls
-r--r--r-- 1 root root 4096 Apr 22 15:11 phc_default_vids
-r--r--r-- 1 root root 4096 Apr 22 15:14 phc_fids
-r--r--r-- 1 root root 4096 Apr 22 15:14 phc_version
-rw-r--r-- 1 root root 4096 Apr 22 15:11 phc_vids
-r--r--r-- 1 root root 4096 Apr 22 15:14 related_cpus
-r--r--r-- 1 root root 4096 Apr 22 15:11 scaling_available_frequencies
-r--r--r-- 1 root root 4096 Apr 22 14:53 scaling_available_governors
-r--r--r-- 1 root root 4096 Apr 22 15:14 scaling_cur_freq
-r--r--r-- 1 root root 4096 Apr 22 15:14 scaling_driver
-rw-r--r-- 1 root root 4096 Apr 22 15:11 scaling_governor
-rw-r--r-- 1 root root 4096 Apr 22 15:14 scaling_max_freq
-rw-r--r-- 1 root root 4096 Apr 22 15:14 scaling_min_freq
-rw-r--r-- 1 root root 4096 Apr 22 15:14 scaling_setspeed
drwxr-xr-x 2 root root    0 Apr 22 15:14 stats
For example:

Code: Select all

$ less /sys/devices/system/cpu/cpu0/cpufreq/phc_default_vids
read error  (press RETURN)
Whereas:

Code: Select all

$ less /sys/devices/system/cpu/cpu0/cpufreq/phc_version
0.3.2:3
/sys/devices/system/cpu/cpu0/cpufreq/phc_version (END)
And when I try to run the intel-phc-undervolt script to set voltages:

Code: Select all

$ ./intel-phc-undervolt 
[ ... snipped intro and warning ... ]
Do you want to continue? [Y/n/?] Yes
> ERROR: No CPU core capable of undervolting found.
I have used (and loved) PHC on this same machine with 'Buntu 12.04 in the past, so I'm pretty sure it should work, but despite having spent quite a while reading through the posts here in the forum I've not been able to get any further than this. Any help much appreciated!

lio
Posts: 74
Joined: Wed 2. Mar 2011, 18:37

Re: Kernel 3.13 on Pentium M with PHC rev.14 - no worky?

Post by lio » Sun 18. May 2014, 09:55

What Distribution do you use? Ubuntu? You can ignore the compile warning and assuming Ubuntu, modprobe -r is expected to fail as acpi-cpufreq is built-in and can't be removed (only modules can be removed). Which kernel version did work for you? (Ubuntu 12.04 should be something like >=3.2) Did you need to workaround http://www.linux-phc.org/forum/viewtopic.php?f=8&t=4984 back then?

lio

Bluubekt
Posts: 9
Joined: Tue 22. Nov 2011, 17:32

Re: Kernel 3.13 on Pentium M with PHC rev.14 - no worky?

Post by Bluubekt » Sat 2. Aug 2014, 18:17

I'm using Xubuntu 14.04 (Trusty), with kernel 3.13.0-32-generic. I saw that there was a new release of PHC in June (rev15.1) so I just had another go at getting it to work. First I uninstalled the previous module and then I built the 15.1 module and "sudo make dkms_install". The module again built and installed without errors, though I still got the warning "ISO C90 forbids mixed declarations and code", which again I assume is safe to ignore. Sadly the situation remains the same after rebooting, the module is loaded and the phc_* files exist in /sys/devices/system/cpu/cpu0/cpufreq/ but apart from phc_version (which still contains "0.3.2:3" by the way) they are all null files.

I'm really unhappy about how hot and unpleasant my laptop gets and desperately miss the dramatic improvement PHC can offer. I'm also a bit frustrated by how much time I've wasted trying to get this to work :( Please, if anyone knows what I need to do to get PHC to work with kernel 3.13 on a Pentium M, do let me know!

Edit: After reading about the workaround suggested by lio it does sound as if this could be relevant - it refers to a kernel patch that fixes the core detection for uniprocessor chips (such as the Pentium M). See the patch here. I will try this, but I find it incredibly silly to have to go through the pain of building (and maintaining!) my own kernel just for this microscopic change :(

jones23
Posts: 1
Joined: Mon 1. Sep 2014, 06:37

Re: Kernel 3.13 on Pentium M with PHC rev.14 - no worky?

Post by jones23 » Mon 1. Sep 2014, 07:28

Hi,
Could you please post if you had success with your efforts ?
I'm am a complete Linux noob , but I was thinking about trying Xubuntu on my old MSI S260 with a Pentium M730.
But without a working solution to undervolt the processor the old machine would simply be too loud to properly use it.

Thanks.

Bluubekt
Posts: 9
Joined: Tue 22. Nov 2011, 17:32

Re: Kernel 3.13 on Pentium M with PHC rev.14 - no worky?

Post by Bluubekt » Mon 1. Sep 2014, 11:44

jones23 wrote:Could you please post if you had success with your efforts ?
I spent quite some time trying to build my own kernel, but wasn't able to get it to boot, something to do with INITRAMFS or something; the disk controller driver fails to load and all drives are inaccessible. This happened even when I used the current config, with no changes. I asked about it on Stack Exchange but even with that help I couldn't make it work. Frustrating that it has to be like this - I have built kernels in the past with less trouble, but the Linux world keeps changing its mind about how things should be done, constantly breaking stuff in the process. *sigh* Needless to say, building a kernel on a 2GHz single core laptop takes rather a long time(!), so after a handful of attempts I simply gave up.

Lio has been quite helpful though, even providing a patched version of PHC for me to try, but that still didn't work and he hasn't got back to me yet. I appreciate that this is something he's doing in his spare time, and without getting paid, so I'm not really blaming him! Hopefully there will be a solution eventually...

Post Reply