diff options
author | Grazvydas Ignotas | 2016-10-20 09:51:25 +0200 |
---|---|---|
committer | Alex Deucher | 2016-10-21 17:19:18 +0200 |
commit | 8861a8209782faffedb6d64572fa968ee9c1c375 (patch) | |
tree | 53e6e4804b506df786c716f1870d18050cadf487 /drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c | |
parent | drm/amd/powerplay: fix static checker warning in process_pptables_v1_0.c (diff) | |
download | kernel-qcow2-linux-8861a8209782faffedb6d64572fa968ee9c1c375.tar.gz kernel-qcow2-linux-8861a8209782faffedb6d64572fa968ee9c1c375.tar.xz kernel-qcow2-linux-8861a8209782faffedb6d64572fa968ee9c1c375.zip |
drm/amd/powerplay: don't give up if DPM is already running
Currently the driver crashes if smu7_enable_dpm_tasks() returns early,
which it does if DPM is already active. It seems to be better just to
continue anyway, at least I haven't noticed any ill effects. It's also
unclear at what state the hardware was left by the previous driver, so
IMO it's better to always fully initialize.
Way to reproduce:
with GPU passthrough.
forced power off the VM or forced reset the VM
without shutting down the Os.
Signed-off-by: Grazvydas Ignotas <notasas@gmail.com>
Reviewed-by: Edward O'Callaghan <funfunctor@folklore1984.net>
Reviewed-by: Rex Zhu <Rex.Zhu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c')
-rw-r--r-- | drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c index 13333d01d2ef..75854021f403 100644 --- a/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c +++ b/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c @@ -1168,8 +1168,8 @@ int smu7_enable_dpm_tasks(struct pp_hwmgr *hwmgr) tmp_result = (!smum_is_dpm_running(hwmgr)) ? 0 : -1; PP_ASSERT_WITH_CODE(tmp_result == 0, - "DPM is already running right now, no need to enable DPM!", - return 0); + "DPM is already running", + ); if (smu7_voltage_control(hwmgr)) { tmp_result = smu7_enable_voltage_control(hwmgr); |