Return to Level1Techs.com

How to overclock Vega on Linux...?

amdgpu
overclocking
vega
#61

I ran in to the same issues when testing out OC on my Vega 56. WattmanGTK reads the changes fine. But the core clock and voltage don’t actually appear to change. Memory clock and power Target are working as expected

1 Like

#63

This is what I use for my radeon vii after the aforementioned kernel parameter has been added.

#!/bin/bash
fan=ls /sys/class/drm/card0/device/hwmon/

function set_gpu_fan_speed(){
#cat /sys/class/drm/card0/device/hwmon/hwmon4/pwm1_enable
echo β€œ1” > /sys/class/drm/card0/device/hwmon/$fan/pwm1_enable
#cat /sys/class/drm/card0/device/hwmon/hwmon4/pwm1
echo β€œ255” > /sys/class/drm/card0/device/hwmon/$fan/pwm1
}

function set_gpu_mem_clk(){
echo β€œmanual” > /sys/class/drm/card0/device/power_dpm_force_performance_level
echo β€œm 1 1200” > /sys/class/drm/card0/device/pp_od_clk_voltage
}

function set_gpu_clocks(){
echo 300000000 > /sys/class/drm/card0/device/hwmon/$fan/power1_cap
echo β€œvc 2 1925 1125” > /sys/class/drm/card0/device/pp_od_clk_voltage
echo β€œs 1 1800” > /sys/class/drm/card0/device/pp_od_clk_voltage
}

function commit_gpu_config(){
echo β€œc” > /sys/class/drm/card0/device/pp_od_clk_voltage &&
echo β€œ2” > /sys/class/drm/card0/device/pp_dpm_mclk &&
echo β€œ6 7” > /sys/class/drm/card0/device/pp_dpm_sclk
}

function monitor_gpu(){
watch -n 0.5 cat /sys/kernel/debug/dri/0/amdgpu_pm_info
}

function main(){
set_gpu_fan_speed
set_gpu_mem_clk
set_gpu_clocks
commit_gpu_config
monitor_gpu
}

main
strong text

BTW, it must be run as the root user.

Perhaps it can be adjusted to work for you.

1 Like

#64

I have an issue with AMDGPU on kernel 5.0.3 after applying below custom table

#!/bin/bash
echo 300000000 > /sys/class/drm/card0/device/hwmon/hwmon0/power1_cap

echo β€œmanual” > /sys/class/drm/card0/device/power_dpm_force_performance_level

echo β€œs 1 991 850” > /sys/class/drm/card0/device/pp_od_clk_voltage
echo β€œs 2 1084 900” > /sys/class/drm/card0/device/pp_od_clk_voltage
echo β€œs 3 1138 950” > /sys/class/drm/card0/device/pp_od_clk_voltage
echo β€œs 4 1200 975” > /sys/class/drm/card0/device/pp_od_clk_voltage
echo β€œs 5 1401 990” > /sys/class/drm/card0/device/pp_od_clk_voltage
echo β€œs 6 1536 1050” > /sys/class/drm/card0/device/pp_od_clk_voltage
echo β€œs 7 1630 1080” > /sys/class/drm/card0/device/pp_od_clk_voltage
echo β€œm 3 1100 1000” > /sys/class/drm/card0/device/pp_od_clk_voltage
#fan at 100%
echo β€œ1” > /sys/class/drm/card0/device/hwmon/hwmon0/pwm1_enable
echo β€œ255” > /sys/class/drm/card0/device/hwmon/hwmon0/pwm1
#commit and apply max states
echo β€œc” > /sys/class/drm/card0/device/pp_od_clk_voltage
echo β€œ3” > /sys/class/drm/card0/device/pp_dpm_mclk
echo β€œ7” > /sys/class/drm/card0/device/pp_dpm_sclk

Voltage stucks at 1.2V and card heavily thermal throttles. Such table works without issues on other OS. I read thru kernel documentation at https://www.kernel.org/doc/html/latest/gpu/amdgpu.html but did not find any clue why voltages don’t apply.

0 Likes

#65

Perhaps similar to my experience here: Using Vega with GNU/linux

0 Likes