controlling CPU boost
Is there a way to manage CPU clock speeds in bazzite similar to windows power management?
My CPU is boosting up to 4-5ghz in games and reaching 90°c faster than my fans can ramp up. This is on both 20w and 25w power settings. In windows I would have a similar problem when the system power management was set to performance mode while balanced and efficiency offered regular 2-4ghz clock speeds and normal temps. It seems bazzite is running like windows performance mode which is causing crazy temps and stealing all the wattage from the iGPU…
207 Replies
AMD?
if AMD, there's a few things you can try:
- change CPU power governor and epp to power/powersave
- change from amd_pstate to acpi_cpufreq for to unlock CPU boost controls, and turn off CPU boost
- wait til kernel 6.11 is released, it should support CPU boost controls on amd_pstate
Legion Go. How can I change my power governance settings? That’s exactly what I need to do as I don’t want to fully disable CPU boost, just want to stop sending all of the power budget to the CPU.
SimpleDeckyTDP has settings for power governor and epp
or alternatively, you can manually setup a bash script + systemd script of some sort that changes the governor and epp
you can also set a TDP + force a min GPU clock, that'll forcibly throttle CPU since resources will need to get allocated to the GPU
if you prefer an alternative to TDP control, you can still leave SDTDP installed and just disable the TDP and GPU controls
Great advice idk why I didn’t think of that. Is there a way I can I change the CPU governance without simpledeckyTDP? I prefer HDDs solution to TDP management
install simpledeckyTDP, disable TDP controls in the plugin
and just use the power governor controls there
there's a toggle in the plugin
ahh, but hhd forces it to be uninstalled
I tried that earlier when attempting to fix this and HDD won’t manage my TDP while SimpledeckyTDP is installed
Exactly
@antheas any way to not have hhd forcible disable SDTDP?
SDTDP has an option to disable tdp and gpu controls
it doesnt force disable it
you can't have them both installed
ah yea, but now hhd has gpu controls
sorry that's what i meant
but no power governor and epp controls
thats by design unfortunately
@HoodieWoody sounds like it's not possible currently then
the reason is what Hoodie experienced
you'll instead need to manually change the governor and epp
people set the governor to performance
and then they get issues
what's bazzite's default epp and governor?
if you reboot the governor will reset
but what's the default?
governor should be powersave
epp i dont know but i will assume a sane default since no one complains
@HoodieWoody did you already reboot after uninstalling SDTDP?
Any chance this isn’t the case? I’ve rebooted quite a few times and I have a feeling it hasn’t gone back to power saving
might be epp performance then
if thats the case im sorry Hoodie it wasnt something that you did
maybe system76 scheduler getting disabled broke the current bazzite ver
Would reinstalling SDTDP to change the settings back possibly work? I understand where I messaged up now, that’s on me. If I can fix it I won’t make the mistake again
the settings don't persist on reboot
SDTDP will not tell you what the governor was
it will force set it
if you want to check the defaults after rebooting i dont have them but Aru has the files
if theres indeed an issue we'll fix it
@HoodieWoody basically without SDTDP, you'll probably have to setup a systemd bash script that changes the EPP and power governor automatically on boot
also check
btop
for rogue programs
if there is an issue, it needs to be fixed in bazzitethis is assuming governor and epp are the issue in the first place
the default should work almost perfectly always
theres only a 5% difference with messing with it
@HoodieWoody i'd say install SDTDP and see if you still see the problem with the powersave governor + epp
also that yea
I had SDTDP first and definitely change some settings before using HDD. I believe this is on me. I know the governance doesn’t persist on boot but I does the EPP persist? Both are options in SDTDP
if you still see the problem, the issue is not the governor or epp
neither does
no, neither option persists on reboot
also note that bazzite had some changes last version so it might not be your fault
no settings in SDTDP persist if you uninstall it + reboot
Sounds good. I’ll experiment more. Genuinely appreciate the help from both of you
you should try to confirm if governor and epp would fix your issue at all. the problem could possibly be something else entirely
Basically see if SDTDP fixes the issue? Just to clarify if I’m using SDTDP I should have both toggles set to efficiency mode? “Power Governor” and “ Energy Performance Preference”
sure, that's one way to do it
What’s a better way? Sorry if I misunderstood. I’m down to try whatever and report back
it's not that there's a better way, there's several ways to do it. you can also manually set EPP and governor via terminal
power governor needs to be powersave always
EPP you can mess with but i havent heard much of a benefit
and either end of it i think is not great
i think half of the options are worthwhile
dont recall which
there's been cases where power governor performance has made differences for games for me, but I don't really encounter it often
i usually default to powersave for both
btw @antheas not sure if you'd be interested in fine-tuning your SDTDP detection in hhd, but hhd could read the SDTDP json and see if TDP + GPU controls are enabled or not.
Could you possibly give me the terminal commands? I’m going to try and not use SDTDP because of the conflict with HDD. Does the terminal command stick past boot?
you can try it
nope, they don't persist on reboot
theres no harm in reinstalling
its one button click to go back anyway
if you're not comfortable with terminal, it'll be easier to just install SDTDP, try it, then uninstall it after + reboot
hhd will autodisable
I guess I’m kinda confused. I thought you guys were saying I shouldn’t use SDTDP if I plan to use HDD?
you cant use both at the same time
but theres no harm in using either
use SDTDP to confirm if the governor and epp is the issue in the first place. for all we know, your problem is not governor and epp
cat /sys/devices/system/cpu/amd_pstate/status
actually no
i dunno where the gov values are
this will give you teh governors
cat /sys/devices/system/cpu/cpu*/cpufreq/energy_performance_preference
this will give you the EPP
run these commands after rebooting to know whats upYou’re a real one. Thanks again, I learned a lot 🙏🏼
@antheas @Aru when I ran the first command it said “power saving” and when I ran the EPP command I got “balanced performance” but my fans and clocks speeds were still super high. I do believe there could be some kind of bug with the new update because I switched to SDTDP and enabled “power save” for the EPP and it fixed the issue. Clock speeds are as they should be now for the CPU both on the desktop and in games.
@Kyle Gospo what do you think about this?
balanced power and power being the others?
yea maybe thats incorrect
Something to add, atleast for the legion go your EPP settings seems very important to CPU clock speeds. With it set to Power save the clocks speeds rarely go above 3.2(base clock) and each setting increases the clock speed with performance mode locking it to 5.1ghz(max boost)
i think maybe removing system76 scheduler caused issues
its unfortunate those random programs can cause these random issues
system76 scheduler does not touch power profiles at all
only the nice values of applications
should the default be balanced performance?
how did that happen?
maybe I need to add EPP too
and set that myself
Mario is gonna skewer me
Kind of hard to see but PS mode the CPU stays around 2.3ghz and if I toggle to performance mode it goes to 4.9-5.1ghz
just checked on my steam deck and the default is balance_power
again, we don't change it. Anything here is stock Fedora kernel
System76 never changed it
PPD is untouched from the previous release
could setting it in gnome to performance cause this?
possible
there's a script in our gamescope session that will set it to balanced only if you entered gamemode in power save
if you've manually set performance it should be kept until reboot
balanced what
PPD
what does that equate to
balance_power evidently
Mario submits patches to PPD
i still use tlp
hrm interesting, so it is EPP then? well, good to get confirmation 👍
Probably ppd being set to performance
If you do add epp and governor to hhd, please make it configurable.
I've received a few reports from users on it affecting games like cyberpunk. also apparently can have big performance impacts on ayn loki devices.
forcing both powersave epp and governor isn't ideal for some games, which is why I kept the setting around
Balance power
For epp
the reports I got said that they needed performance governor for some games
Uh well let's see
just reporting what I've received from users ¯\_(ツ)_/¯
that being said, i'm assuming most people are fine with power save epp and governor
What's the difference between balance power and power
for epp, power is poorly named. it's basically powersave
power, balance_power, balance_performance, performance
Yea what's the difference though
Quantitatively
No idea, i never formally measured it in any way. I just read about it in the kernel docs, as well as received reports on it affecting game performance
https://docs.kernel.org/admin-guide/pm/amd-pstate.html#energy-performance-preference-epp-rw
I think adolfo did some benchmarking, etc, with different epp values. maybe he could say more
seems like ppd can become a toggle and thats it
the defaults are reasonable
as long as people do not use performance in low tdps it makes sense
Anyways, for @HoodieWoody , if you want to use HHD for TDP, you can remove SDTDP + setup a systemd service that's hard coded to set powersave EPP on boot and suspend/resume
How would I go about this bro? I don’t mind doing the work
you could probably use this guide, but modify it
https://docs.google.com/document/d/17a0F6Wsdak1ekE6XDUn749BNynU5mj8FH9vpzDWm_bg/edit
Google Docs
AYN Loki Max fan control and CPU Gorvernor
AYN Loki Fan control and CPU optimization (Loki Zero and Loki Mini Pro needs the official BIOS update from AYN for fan (and RGB?) to work correctly, Max and Loki will “just works”! also, I am not sure if Linux will load amd_pstate_epp driver for the CPU in Zero and Mini Pro, but no worry, if it ...
you'd need to delete all the code for fan controls + LEDs
but the power governor stuff is all there
dont do that, go to desktop
make sure this is balanced
🤔 do settings made in desktop mode persist on reboot into gamescope-session?
thats not desktop thats ppd
nice, I had assumed changes made in desktop mode wouldn't apply on reboot. if that works, that'll be better overall
i dont know if it remembers to be honest but
bazzite auto sets it to balanced if its power save
thers no way it defaults to performance
I think @HoodieWoody is looking for a way to set epp to powersave by default
balanced power works almost as well
the problem is balanced performance
which is set when ppd is in performance
In my testing the difference between the different EPP settings are very similar to the CPU boost settings in windows.
Power save= Efficient enabled
Balance power save= boost enabled
Balance Performance = Efficient Aggressive
Performance= Aggressive Boost
I think of "CPU boost" itself as separate from EPP
there's upcoming kernel changes that should enable toggling it on/off
anyways doesn't hurt to try what antheas suggested, it'll be good to know if it persists on reboot
I know it’s very different but the behavior is almost identical. EPP seems to control the boost range just like the 4 different CPU boost options in windows do. Different from the on/off toggle.
yea well its the same code
turning off boost just sets a different upper frequency
i guess another alternative could be to rename the SDTDP plugin so that hhd doesn't detect it, and disable TDP + GPU controls in SDTDP
and use it alongside hhd
if epp is needed i can add it
however i assumed that it was just a footgun
im still convinced it kind of is
almost safer to just offer a PPD control
and let it handle the changing
yea with what gui
drop down between "power save", "balanced", and "performance"
that's all GNOME/KDE do
the reason why I added epp and governor to SDTDP originally was because there was no good gui
and some users were puzzled at why they couldn't get the performance they were seeing on Windows
we already have a tdp slider and a frequency slider, why do we need that
people want a slider that says heres how much i want to burn
and one that says heres how much cpu i want vs gpu
thats it
I think the problem here is that those controls aren't available in gamescope-session
gnome and kde might change them, but as far as i know, gamescope-session doesn't have those controls
anyways, @HoodieWoody keep us updated on what ends up working for ya
that's why the session has the reset
you will always boot to balanced
and if you change it to power save in the desktop and switch back, you get reset to the more sensible balanced
I don't bother w/ performance because users probably have a reason for switching to it
if it doesnt affect the GPU
i think ill just name EPP to Favor CPU, Balanced, Favor GPU
remove the GPU slider
and call it a day
wait, why remove the GPU slider?
why have 2 settings that do the same thing
GPU slider is still useful for setting min GPU clocks 🤔
i implemented frequency pinning only
at the current version
ah, so no GPU frequency range
i thought your implementation was the range with min/max
up to you i guess. but no GPU slider = no feature parity with steam client again. 😅
Currently things are working perfectly with SDTDP with the EPP set to Power saving. Playing 7DTD at 25Watts my CPU stays around 3-3.5ghz(10w) and the GPU is staying close to 1800mhz(15w). This is exactly as the Z1 extreme should perform and the same clocks speeds I would get at 25W in windows. I spent a lot of time messing around with CPU and GPU clocks speeds and reading guides for windows to know those are the ideal clock speeds for the Z1 extreme. I’m probably done messing with it for now as it seem pretty perfect across a handful of games.
did you try the gpu frequency?
is EPP to powersave all thats needed?
Changing the GPU frequency works good too, depending on what I set it leaves the appropriate amount of power budget for the CPU. Yeah EPP to power save seems to be perfect. It acts exactly like “efficient enabled” CPU boost in windows which from my testing and reading was always the recommended option for the Z1 Extreme specifically
Removed SDTDP to try HDD some more. Using the terminal command you gave me I get back balance_performance after a clean boot. I tried setting balanced with the desktop slider and it just keeps going back to balance_performance. Is this the intended behavior? Didn’t you mention Bazzite should default to balance_power?
To me it sounds like the default is balance_performance
PPD is power state aware
I need to look at the rules but it might explain the difference
Balance power versus balance performance
Sounds like undefined behavior that's harming users to me. Hhd-ppd will become a plugin if it can't handle its business
is this done via ujust? is there any reference docs these bits on AMD? i’m seeing slightly higher temps on my 5600x than windows on bazzite 3.5
Nope no ujust, you can look up AMD pstate and EPP online for docs and info
That being said, shouldn't really matter for desktop systems 🤔
Just as a quick follow up, did ya end up fixing the problem?
I tried using HDD again but my clock speeds were a lot less stable. It’s nice to know it’s because of the balanced_performance governor setting tho, makes me feel less blind as to the issue. Switched back to SDTDP for both TDP and EPP management and things have been working great
Nice, good to hear it's been resolved 👍
Can’t stress enough how much I appreciate your guys help 👊🏼❤️ I learned a lot
@Mister Fluffles
ty
So how does this work on steam deck? Does setting a profile in desktop mode have any impact on gaming mode?
The GPU slider in the QAM doesn’t appear and changing governors in PowerTools locks the system to 3500hz if I accidentally pick performance instead of powersave, which needs a reboot to get fixed.
if you enter game mode w/ it set to power save it
will reset to balanced
otherwise, we leave it alone
default at boot is balanced
and performance really shouldn't be used on modern hardware
I guess that aspect of powertools might be a bit bugged since it might expect steamos then. I’ll leave the setting alone.
Was trying to get a bit more automatic powersaving while playing games when I noticed this behaviour. Sometimes the deck likes to ramp up to 2-2,5ghz while 1,2 is more than enough (looking at you classic doom). Gets me hours by manually adjusting gpu/cpu and memory in powertools
Balanced is broken
GPU slider if you installed simpledeckytdp before is enabled
@antheas I’ve got a few new options in HDD in regards to power management. PPD emulation and Energy Management on the TDP page. Any usage tips on how I can try to adjust stuff to get CPU clock speeds down? I’d really love to use HDD instead of SimpleDeckyTDP
we are working on the ppd check which seems to have issues on bazzite
but yeah i brought over all the settings
would love your feedback
low balanced and high cpu is epp
then you have boost and minimum clock
but bazzite doesnt have boost yet unfortunately
an option to disable it
i found out i can control CPU clocks completely though
Awesome I’ll mess around with it as I have downtime today and definitely let you know what I notice. How do you control CPU clocks completely? I’ve looked into this and haven’t found much. A 4ghz upper limit would honestly fix all my issues regardless of what I use to set TDP
you can set the maximum clock per core
also, if you disable boost the maximum clock is 3.2ghz
which is perfect
but bazzite is not carrying a patch for it yet @Kyle Gospo
i only did boost, perhaps could do a fallback but im travelling this week so its tough
No worries I’m patient. I didn’t quite understand your explanation between the PPD emulation and Energy Management settings. Which one does what exactly? They seem mutually exclusive because I’m getting conflict detected when trying to turn energy management on
yes we are working on fixing that
a leftover file from tuned seems to be triggering it
also you need to run that command
Should I use energy management instead of PPD emulation?
its not instead, ppd emulation is an extra feature
so you can control tdp from kde
its disabled because it needs a bit of testing
Gotcha I misunderstood. Awesome I’ll let you know what I find out
its understandable its confusing, most people dont know what ppd is
@antheas I’m having a little trouble enabling still. I’ve rebooted a couple times and keep getting this message
it's being patched in HHD
and a release pushed to do it for you
might just want to wait for that
Is there something I could do to fix it? If not I’m okay with waiting, just got excited to test it out
ujust _hhd-dev
has the hotfix
I'm just waiting for verificationI shall wait than 💪🏼
Can you run the command and see if it fixes it?
wrong spelling here
profiles
not profile
and run w/ sudo
since it's a system service
yup just did and its installing a new version. ill let you know here in just a minute. if not ill run the fixed command
It looks stuck after a point
Just open the desktop app
@antheas warning is gone
also removes the PPD option from GNOME/KDE
but that's probably not an issue
since you can configure it via hhd
Try ppd emulation
From the settings
And reload powerdevil
that worked, shows that I'm in powersave
It's also 2way
but I am in performance
lemme toggle it
Maybe there's a bug on launch
Probably actually
switching it to balanced does nothing
prompt reopens with performance still checked
and gnome still shows power save
Gnome or kde
GNOME
I only tested KDE, ok it's disabled by default
disabling PPD emulation doesn't fix it
We can figure it out next 3 days
The service needs to be reloaded probably though
Don't know how it's called in gnome
actually nvm, clicking any popup closes and shows reopens w/ no change
might just be some goofiness w/ the dev version overlay
I think we're good, PPD emulation seems fine
even if emulation is busted energy management will work now
which is the important part
i tested emulation on kde and it works fine
but i had a scare with it crashing after boot until i fixed some stuff
would this be the correct updated command? "sudo systemctl disable --now power-profiles-daemon"
so im going to let it disabled by default for a few days
after the update no commands
it will just work
i ran the installer and got an updated version but still am struggling to run the command to make energy management work
the next ver will drop in a couple hours
for now if you want to make it work
its this command +
ujust _hhd-dev
got it working, thanks bro. your the real MVP
@antheas Don’t know if this helps at all for the release in a couple hours but my system reverted back to the previous HHD version after I rebooted. Also for some reason the command that worked the first time isn’t working anymore, I’ve ran it 3 times now with and without rebooting. Just says conflict detected no matter what I do
I’m happy to wait for the official release as I don’t want you to have to keep helping me. Thought it might be helpful to know the problems I’m having tho
yeah, says it'll do that in the command
appreciate you testing, next update you'll have it
hopefully by tonight
Got it working again and have tested in a handful of games. System runs much better with CPU power on low but the CPU boost setting doesn’t seem to work, I still get random spikes up into the high 4ghz range. Also setting the GPU clock speed manually doesn’t seem to stop the CPU from spiking as it should
You shouldn't be seeing it
Guess I have some bugs to fix
Rip
Bazzite does not support the boost toggle
@Kyle Gospo delay the release a tiny bit dunno. Can you see the boost toggle?
Yes
Gotcha you mentioned earlier that turning CPU boost off was the easiest fix because 3.2ghz is fine for nearly every game. so I assumed it was intentional.
Yeah but the boost button shows up only if boost is supported
But I didn't test if not because my kernel has the patch
True true. I’ll avoid that than. Still seeing some improvement with the low CPU power so that a huge plus in my eyes
I’m beyond curious why my legion go decides to boost so high still tho. The CPU temp goes up to 88-90 degrees while it’s boosting and then returns back to the high 60s after a moment. No change in frame rate when this happens either. So weird
By default the CPU is set to boost up to 90ish C
Yeah it doesn’t get even close to throttling. It’s just odd behavior to go from 3ghz up to 4.7ghz for no reason at a 48fps cap. It would make a lot more sense if I played games uncapped and there was a lot of variability to the gameplay. I’ll be sitting on the menu of a game and it goes back and forth from 3 to 4.7 with my temps bouncing all over the place. When I was on windows I had this stuff so dialed in that at 48fps my system was ultra stable
Steam is very heavy
Steam on its own is heavier than a lot of games
Especially at 2k resolution
The hhd overlay is a lot smoother
Very true. I also realized yesterday that the CPU temp reading is from the hottest spot on the APU. I did some research and the GPU temp is more indicative of the overall die temperature on APUs like the Z1 Extreme. The fans also run off the GPU sensor so that’s why they weren’t spinning up super fast when the CPU hot spot hits 90° and the IGPU is still in the 70s
Did you post the update? I see the fix posted on the adjustor page on GitHub but no luck with the auto installer
What do you mean?
You mentioned yesterday you were posting a fix for the PPD conflict that’s stopping energy management from working. I see that fix on the adjustor page on GitHub and was wondering if it’s available? I’m not able to download it and the energy management settings were gone this morning
hm is it ticked in settings?
The toggle is only available within the decky plugin not on the desktop but it is checked on.
@Kyle Gospo did the ppd fix get pushed?
@Kyle Gospo hey man super sorry to bother you but I was wondering if I’m possibly doing something wrong or if the Adjustor changes just still haven’t been pushed?
not on main, they are in
:testing
will hit main soon
probably todayAll I needed to know 🫡 appreciate it G
It was found that boost was not set correctly
Will be fixed in next update
@antheas I’ve noticed the last couple days my device has been defaulting to performance mode on the desktop. None of the settings in HDD seem to be effecting it either as I have to lower it manually.
open handheld daemon on desktop
and try the slider
Doesn’t seem to do anything
scroll up
I’m in custom when I’m getting this behavior. Also does it at 20w but at 8 and 15 it changes to power save and balanced
I was under the impression the power profile slider was for CPU power, not TDP? If it’s for TDP than I guess that makes sense what I’m seeing?
i did some magic so now it does tdp
boost should be fixed too, if not, next ver
if you set energy management to auto, it also does that too
its done based on tdp so it always works
I’ve been getting boosts up to 2.5ghz so I’d say it works great. That’s awesome I think that change you made makes a lot of sense 🤘🏼
thanks
@antheas Aye man do you recommend always using STAPM in the bios? Have you tested STT?
im doing stt right now
both work the same kinda if you dont boost
Very interesting.. how does boost make a difference to which one you choose?
STT keeps boosting until your device reaches the temperature threshold of the profile
70-90C
STAPM boosts for 3 minutes flat
custom is either 95C or 100C
but in any case
the boost tdp of the legion go is 2W
Unless legion space has fixed how it sets TDP, STAPM is better for dual boot.
legion space on windows wasn't setting TDP on STT correctly
but otherwise, STT and STAPM shouldn't really make much of a difference for Linux
also, recent legion space + bios updates could've fixed things up on the Windows side too