Also set the platform profile for AMD.

The platform profile sets power settings for the EC/system but not the CPU.
This commit is contained in:
Tom Alexander
2023-12-19 08:51:25 -05:00
parent c87ac216a9
commit 9ac2605912
4 changed files with 24 additions and 3 deletions

View File

@@ -8,6 +8,14 @@ DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
perc=$1
if [ "$perc" -gt 80 ]; then
echo performance | tee /sys/firmware/acpi/platform_profile
elif [ "$perc" -ge 20 ]; then
echo balanced | tee /sys/firmware/acpi/platform_profile
else
echo low-power | tee /sys/firmware/acpi/platform_profile
fi
if [ "$perc" -ge 80 ]; then
echo "performance" | tee /sys/devices/system/cpu/cpufreq/policy*/energy_performance_preference
elif [ "$perc" -ge 60 ]; then

View File

@@ -0,0 +1,2 @@
# Favor energy efficiency for platform profile (EC / system, not CPU)
w- /sys/firmware/acpi/platform_profile - - - - low-power