NGnius / PowerTools

Moved to
https://git.ngni.us/NG-SD-Plugins/PowerTools
GNU General Public License v3.0
413 stars 29 forks source link

Minimum CPU frequency can't be set lower than 1400MHz. #101

Closed k6storama closed 1 year ago

k6storama commented 1 year ago

Please confirm

Expected Behaviour

I'd expect to set minimum CPU frequency below 1400MHz.

Actual Behaviour

Well, like in the title - the minimum CPU frequency can't be set below 1400MHz. It can be set lower with the slider, though it has no actual effect; the minimum CPU clock speed & the value inside the game profile config is still at 1400. The maximum frequency can be set lower than 1400MHz, making the minimum frequency higher than the maximum, and locking the actual CPU frequency at maximum frequency value as result. This happens with every game I've tested, as well as in Steam Deck main menu ("Main" profile).

Steps To Reproduce

  1. Start the game
  2. Open PowerTools settings
  3. Enable CPU Frequency Limits
  4. Set the minimum CPU frequency below 1400MHz
  5. Enable Persistent Profile
  6. Check the CPU frequencies with e.g. mangohud, restart the game to see the minimum CPU frequency slider at 1400MHz or check the game profile config (~/.config/powertools/GameID.json)

Anything else?

Before the game restart: 7_20230511194952_1 After restart: 7_20230511195028_1 Log file: powertools.log - Pastebin

Version

1.3.1 (Latest stable)

Platform

Steam Deck

OS

SteamOS 3 (Stable)

NGnius commented 1 year ago

This is intended behavior, since the kernel does not allow minimum values lower than 1400MHz. It's also the reason for this slightly strange comment.

https://github.com/NGnius/PowerTools/blob/main/backend/src/settings/steam_deck/cpu.rs#L431

k6storama commented 1 year ago

Oh okay, thank you for the answer!