[PATCH Review 1/1] drm/amdgpu: Fix ineffective ras_mask settings

Stanley.Yang Stanley.Yang at amd.com
Fri Dec 22 07:01:46 UTC 2023


For the special asic with mem ecc enabled but sram ecc
not enabled, even if the ras block is not supported on
.ras_enabled, if the asic supports poison mode and the
ras block has ras configuration, it can be considered
that the ras block supports ras function only with sram
ecc is not enabled, otherwise the modprobe argument ras
feature mask is ineffective.

Signed-off-by: Stanley.Yang <Stanley.Yang at amd.com>
---
 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 1d5c9d84f51d..8448e11d3e20 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c
@@ -3405,7 +3405,8 @@ int amdgpu_ras_is_supported(struct amdgpu_device *adev,
 	     block == AMDGPU_RAS_BLOCK__VCN ||
 	     block == AMDGPU_RAS_BLOCK__JPEG) &&
 	    amdgpu_ras_is_poison_mode_supported(adev) &&
-	    amdgpu_ras_get_ras_block(adev, block, 0))
+	    amdgpu_ras_get_ras_block(adev, block, 0) &&
+		!amdgpu_atomfirmware_sram_ecc_supported(adev))
 		ret = 1;
 
 	return ret;
-- 
2.25.1



More information about the amd-gfx mailing list