Commit daf8de08 authored by Alex Deucher's avatar Alex Deucher

drm/amdgpu: always reset the asic in suspend (v2)

If the platform suspend happens to fail and the power rail
is not turned off, the GPU will be in an unknown state on
resume, so reset the asic so that it will be in a known
good state on resume even if the platform suspend failed.

v2: handle s0ix
Acked-by: default avatarLuben Tuikov <luben.tuikov@amd.com>
Acked-by: default avatarEvan Quan <evan.quan@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 8c45096c
...@@ -2154,7 +2154,10 @@ static int amdgpu_pmops_suspend(struct device *dev) ...@@ -2154,7 +2154,10 @@ static int amdgpu_pmops_suspend(struct device *dev)
adev->in_s3 = true; adev->in_s3 = true;
r = amdgpu_device_suspend(drm_dev, true); r = amdgpu_device_suspend(drm_dev, true);
adev->in_s3 = false; adev->in_s3 = false;
if (r)
return r;
if (!adev->in_s0ix)
r = amdgpu_asic_reset(adev);
return r; return r;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment