drm/amdgpu: Enable default GPU reset for dGPU on gfx8/9 v2
Subsystems (2)
PATCH v2 1/1 drm/amdgpu: Enable default GPU reset for dGPU on gfx8/9 v2
After testing looks like these subset of ASICs has GPU reset working for the most part. Enable reset due to job timeout.
v2: Switch from GFX version to ASIC type.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 30 ++++++++++++++++++++++++++---- 1 file changed, 26 insertions(+), 4 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +26 -4
@@ -3297,13 +3297,35 @@ bool amdgpu_device_should_recover_gpu(struct amdgpu_device *adev)return false; } -if (amdgpu_gpu_recovery ==0 || (amdgpu_gpu_recovery ==-1 && - !amdgpu_sriov_vf (adev))) { -DRM_INFO ("GPU recovery disabled.\n" ); -return false; +if (amdgpu_gpu_recovery ==0 ) + goto disabled; + +if (amdgpu_sriov_vf (adev)) +return true; + +if (amdgpu_gpu_recovery ==-1 ) { +switch (adev->asic_type) { +case CHIP_TOPAZ : +case CHIP_TONGA : +case CHIP_FIJI : +case CHIP_POLARIS10 : +case CHIP_POLARIS11 : +case CHIP_POLARIS12 : +case CHIP_VEGAM : +case CHIP_VEGA20 : +case CHIP_VEGA10 : +case CHIP_VEGA12 : +break ; +default : + goto disabled; + } }return true; + +disabled: +DRM_INFO ("GPU recovery disabled.\n" ); +return false; }/**
Signature · 6 lines
2.7.4 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
A message that is not in the archive (sent off-list or not yet received): 1540313370-28335-1-git-send-email-andrey.grodzovsky-5C7GfCeVMHo@public.gmane.org
Alex Deucher
Acked-byQuoted 7 lines · Andrey Grodzovsky
After testing looks like these subset of ASICs has GPU reset working for the most part. Enable reset due to job timeout.
v2: Switch from GFX version to ASIC type.
Signed-off-by Andrey Grodzovsky <[email protected]>
Quoted 51 lines
--- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 30 ++++++++++++++++++++++++++---- 1 file changed, 26 insertions(+), 4 deletions(-)drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +26
-5@@ -3297,13 +3297,35 @@ bool amdgpu_device_should_recover_gpu(struct amdgpu_device *adev)return false; } -if (amdgpu_gpu_recovery ==0 || (amdgpu_gpu_recovery ==-1 && - !amdgpu_sriov_vf (adev))) { -DRM_INFO ("GPU recovery disabled.\n" ); -return false; +if (amdgpu_gpu_recovery ==0 ) + goto disabled; + +if (amdgpu_sriov_vf (adev)) +return true; + +if (amdgpu_gpu_recovery ==-1 ) { +switch (adev->asic_type) { +case CHIP_TOPAZ : +case CHIP_TONGA : +case CHIP_FIJI : +case CHIP_POLARIS10 : +case CHIP_POLARIS11 : +case CHIP_POLARIS12 : +case CHIP_VEGAM : +case CHIP_VEGA20 : +case CHIP_VEGA10 : +case CHIP_VEGA12 : +break ; +default : + goto disabled; + } }return true; + +disabled: +DRM_INFO ("GPU recovery disabled.\n" ); +return false; }/** -- 2.7.4
Quoted 4 lines
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Am 23.10.18 um 18:49 schrieb Andrey Grodzovsky:
Quoted 41 lines
After testing looks like these subset of ASICs has GPU reset working for the most part. Enable reset due to job timeout.
v2: Switch from GFX version to ASIC type.
Signed-off-by Andrey Grodzovsky <[email protected]>--- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 30 ++++++++++++++++++++++++++---- 1 file changed, 26 insertions(+), 4 deletions(-)drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +19
-4@@ -3297,13 +3297,35 @@ bool amdgpu_device_should_recover_gpu(struct amdgpu_device *adev)return false; } -if (amdgpu_gpu_recovery ==0 || (amdgpu_gpu_recovery ==-1 && - !amdgpu_sriov_vf (adev))) { -DRM_INFO ("GPU recovery disabled.\n" ); -return false; +if (amdgpu_gpu_recovery ==0 ) + goto disabled; + +if (amdgpu_sriov_vf (adev)) +return true; + +if (amdgpu_gpu_recovery ==-1 ) { +switch (adev->asic_type) { +case CHIP_TOPAZ : +case CHIP_TONGA : +case CHIP_FIJI : +case CHIP_POLARIS10 : +case CHIP_POLARIS11 : +case CHIP_POLARIS12 : +case CHIP_VEGAM : +case CHIP_VEGA20 : +case CHIP_VEGA10 : +case CHIP_VEGA12 : +break ;
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c bool amdgpu_device_should_recover_gpu(struct amdgpu_device *adev) · line 3328
Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +7
-0+default : + goto disabled; + } }return true; + +disabled: +DRM_INFO ("GPU recovery disabled.\n" ); +return false;
The indentation here is wrong, with that fixed the patch is Reviewed-by: Christian König <[email protected]>.
Christian.
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c bool amdgpu_device_should_recover_gpu(struct amdgpu_device *adev) · line 3331
Quoted 3 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +0
-0}/**
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx