-
Notifications
You must be signed in to change notification settings - Fork 554
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] update-amd-tdp #13157
base: master
Are you sure you want to change the base?
[WIP] update-amd-tdp #13157
Conversation
e780702
to
e7267c7
Compare
e92d6fd
to
e0cfa5c
Compare
if [ "$EVENT" == "gameStop" ]; then | ||
# set user global setting | ||
TDP_SETTING=$(printf "%.0f" "$(/usr/bin/batocera-settings-get global.tdp)") | ||
if [ -z "${TDP_SETTING}" ]; then | ||
echo "No TDP setting defined, cannot set TDP." >> $log |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What happens if a user has global.tdp
set to "auto" (it's not set in batocera.conf
), but has TDP set for a system or a game? It seems like when the game stops, this branch would not revert the game TDP settings.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If a user has a per system or per game but not global tdp setting it now checks the current tdp value, and if does not equal the system.cpu.tdp determined at boot, indicating it was changed, it then restores to system.cpu.tdp
@bryanforbes thanks for reviewing, I’ll fix some of the obvious stuff I missed in the first draft of changes. The issue with a system or game tdp value but not global I didn’t even think of, I’ll address that as well. I’ll try to find time this coming weekend to work on it. |
Update es_features.yml Update tdp_hooks.sh Update batocera-amd-tdp Update batocera-amd-tdp amd-tdp-update
e0cfa5c
to
cf64868
Compare
Updated PR to resolve prior issues and clean up some. Also changed the resume script to better handle situations where if a user has a per system/game tdp value and suspends while a game is running it will save tdp, suspend, resume, and the revert back to saved tdp value. This is needed since ryzenadj changes do not persist after suspend. |
Aims to change behavior of amd TDP scripts to account for new slider which when set to "auto" will not have an entry in batocera.conf and should allow system bios to determine tdp values.
Improved resume script which now saves the current tdp to a temp file if it does not equal system.cpu.tdp, which is then used to revert back to after resume. This should handle situations where a user suspends while a game is running ensuring per system/game setting is kept.
Refactor code for better readability.
stapm/fast/slow set to same tdp value.
Also removed hard coded temp limit so bios can handle it. May be beneficial to include a separate temp limit slider which could be used in the future.