Skip to content
This repository has been archived by the owner on Aug 14, 2023. It is now read-only.

Powersave governor by default making config.txt overclocking difficult #15

Closed
m3adow opened this issue Nov 16, 2015 · 5 comments
Closed

Comments

@m3adow
Copy link

m3adow commented Nov 16, 2015

On a newly installed Hypriot "Hector" 0.6, the default governor is powersave. To quote kernel.org:

2.2 Powersave
The CPUfreq governor "powersave" sets the CPU statically to the
lowest frequency within the borders of scaling_min_freq and
scaling_max_freq.

This effectively makes overclocking with config.txt impossible without changing the governor via startup script. I can't confirm it's the same for 0.61, but the kernel configs seem to imply that.

Of course I may be in the wrong, but I doubt this is intended. I'd recommend setting it either to ondemand or conservative.

@MathiasRenner
Copy link
Collaborator

@m3adow Thanks for filing this, I will have a look at it! We did not discuss this issue for the very latest release since we wanted to release it in time for the DockerCon :-)

@MathiasRenner
Copy link
Collaborator

Hmm, I tested a fresh HypriotOS 0.6.1 and saw the CPU frequency immediately switching from 600 to 900 Mhz when stress --cpu 4 is executed.

sudo cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_cur_freq 
900000

Also, the governor by default is ondemand, even if the script suggests that powersafe is default.

cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
ondemand

A few lines below the powersafe default option, ondemand is in general enabled:
https://github.com/hypriot/rpi-kernel/blob/master/kernel_configs/rpi2_docker_kernel_config#L522-L526

So it seems that onemdand works fine. Could you please double check this with the latest image on your site?

Finally I created a /boot/config.txt - it did not seem to change anything. What do you expect to happen with these lines from your comment in Gitter?

arm_freq=900
core_freq=333
sdram_freq=450
over_voltage=2

@m3adow
Copy link
Author

m3adow commented Nov 17, 2015

So it seems that onemdand works fine. Could you please double check this with the latest image on your site?

No sorry, I can't reflash my Pis for a couple of weeks at least, so I'm still running on 0.6. It seems the bug is fixed in 0.61 then.

Finally I created a /boot/config.txt - it did not seem to change anything. What do you expect to happen with these lines from your comment in Gitter?

arm_freq=900
core_freq=333
sdram_freq=450
over_voltage=2

I don't think I understand the intention of your question, but I'll try answering it.
I expect exactly what is documented (https://www.raspberrypi.org/documentation/configuration/config-txt.md). I'm using additional values, specifically smaller min values for less power consumption, I just removed those as it wasn't important. arm_min_freq values work as well with a proper governor.

@MathiasRenner
Copy link
Collaborator

Still, thanks for your feedback. This would have definitely been a bug.

I intended to know what the parameters in /boot/config.txt do. Thanks for the link, this is what I was looking for.

I tried some kind of undervoltage and set arm_freq, sdram-freq and similar parameters to about half of the default value, but I only saved about 0.2 Watts. Do you gain more saving effects?

@m3adow
Copy link
Author

m3adow commented Nov 17, 2015

I can't say how much I got exactly as I only have the result of a calculation I made over one year ago. Back then my Pis were idle for 90% of the time and I underclocked them heavily (I think to 100MHz or something like that) which according to my calculation saved me ~15€/year. Not a lot, but why pay for something I don't use?

Nevertheless, this is more a topic for Gitter and not for an issue tracker. As the problem doesn't seem to exist on 0.61 anymore, I consider this done. Should probably still be changed here for improved clarity.

@m3adow m3adow closed this as completed Nov 17, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants