cpu_frequency restore wrong governor
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
powernap |
Fix Released
|
Undecided
|
Andres Rodriguez | ||
powernap (Ubuntu) |
Fix Released
|
High
|
Unassigned |
Bug Description
Binary package hint: powernap
Hello,
when first invoked, the /etc/pm/
However that might happen when the active governor is not (yet) set to the desired one.
For example during the boot sequence.
In my case the desired active governor (ondemand) is set at boot time by the cpufrequtils init.d script.
However during the boot sequence powernap is started before cpufrequtils (at least here), and the governor written in /var/run/powernap is the wrong one (performance, which was active before cpufrequtils run)
Latter when powernap runs the powersave actions, it correctly set the governor to 'powersave', but when the recover actions are taken, cpu_frequency set the governor to performance (which is what /var/run/
I have modified /etc/pm/
Now /var/run/
That way powernap doesn't silently override the governor set by cpufrequtils init.d script, or any governor change made when the machine is not idled.
tags: | added: patch |
Changed in powernap (Ubuntu): | |
status: | In Progress → Confirmed |
importance: | Undecided → Wishlist |
assignee: | Andres Rodriguez (andreserl) → nobody |
Changed in powernap: | |
status: | In Progress → Fix Committed |
Changed in powernap (Ubuntu): | |
importance: | Wishlist → High |
Changed in powernap: | |
status: | Fix Committed → Fix Released |
Hi Mathieu,
Thank your for reporting bugs and trying to make PowerNap and Ubuntu Server better.
I have looked into this and in fact this is not an issue with PowerNap directly, but rather with acpi-support/ ondemand init scripts.
1. When the machine boots up, then it executes the acpi-support init script d/ondemand init script sets the CPUFREQ to ondemand.
2. This init scripts, also executes the /etc/acpi/power.sh script.
3. Then, the power.sh script, executes pm-powersave (which cases all the scripts installed by powernap to be executing during boot time)
4. Way after this is done, the /etc/init.
This mean that the ondemand frequency is set to ondemand way after pm-powersave has been executed, causing the cpu_frequency script to save the "incorrect" governor.
Thank you for pointing this out. Your patch looks good. I'm merging it.
Cheers,