The original logic skips RAS error reset whenever GPU is in reset or RAS recovery. This change adds amdgpu_uniras_enabled() condition, so we only skip the reset when uniras is enabled. For ASICs without uniras, we still perform RAS error reset during GPU reset.
Signed-off-by: Ce Sun <[email protected]> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c index 6b2b8acdbf9b..c65916d84683 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c @@ -1513,7 +1513,8 @@ int amdgpu_ras_reset_error_count(struct amdgpu_device *adev, return -EOPNOTSUPP; /* skip ras error reset in gpu reset */ - if (amdgpu_in_reset(adev) || amdgpu_ras_in_recovery(adev)) + if ((amdgpu_in_reset(adev) || amdgpu_ras_in_recovery(adev)) && + amdgpu_uniras_enabled(adev)) return -EOPNOTSUPP; if (block_obj->hw_ops->reset_ras_error_count) -- 2.34.1
