Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 9 additions & 3 deletions func.d/45-tlp-func-gpu
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,9 @@ set_amdgpu_profile () {
if [ -f "$gpu/device/power_dpm_force_performance_level" ]; then
# Use amdgpu dynamic power management method (DPM)
case "$1" in
"$PP_PRF") level=${RADEON_DPM_PERF_LEVEL_ON_AC:-} ;;
"$PP_BAL"|"$PP_SAV") level="${RADEON_DPM_PERF_LEVEL_ON_BAT:-}" ;;
"$PP_PRF") level="${RADEON_DPM_PERF_LEVEL_ON_AC:-}" ;;
"$PP_BAL") level="${RADEON_DPM_PERF_LEVEL_ON_BAT:-}" ;;
"$PP_SAV") level="${RADEON_DPM_PERF_LEVEL_ON_SAV:-$RADEON_DPM_PERF_LEVEL_ON_BAT}" ;;
esac

if [ -z "$level" ]; then
Expand All @@ -169,10 +170,15 @@ set_amdgpu_profile () {
pwr="${RADEON_DPM_STATE_ON_AC:-}"
;;

"$PP_BAL"|"$PP_SAV")
"$PP_BAL")
level="${RADEON_DPM_PERF_LEVEL_ON_BAT:-}"
pwr="${RADEON_DPM_STATE_ON_BAT:-}"
;;

"$PP_SAV")
level="${RADEON_DPM_PERF_LEVEL_ON_SAV:-$RADEON_DPM_PERF_LEVEL_ON_BAT}"
pwr="${RADEON_DPM_STATE_ON_SAV:-$RADEON_DPM_STATE_ON_BAT}"
;;
esac

if [ -z "$pwr" ] || [ -z "$level" ]; then
Expand Down
2 changes: 2 additions & 0 deletions tlp.conf.in
Original file line number Diff line number Diff line change
Expand Up @@ -385,13 +385,15 @@

#RADEON_DPM_PERF_LEVEL_ON_AC=auto
#RADEON_DPM_PERF_LEVEL_ON_BAT=auto
#RADEON_DPM_PERF_LEVEL_ON_SAV=low

# Dynamic power management method (DPM): balanced, battery, performance.
# Note: radeon driver only.
# Default: <none>

#RADEON_DPM_STATE_ON_AC=performance
#RADEON_DPM_STATE_ON_BAT=battery
#RADEON_DPM_STATE_ON_SAV=battery

# Display panel adaptive backlight modulation (ABM) level: 0(off), 1..4.
# Values 1..4 control the maximum brightness reduction allowed by the ABM
Expand Down