Skip to contentSkip to conversation

drm/amdgpu: Fix ineffective ras_mask settings

PATCH In review Stanley.Yang 2 participants 2 messages Feb 21, 2024 – Feb 22, 2024

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/amdgpu: Fix ineffective ras_mask settings

Check amdgpu_ras_mask to fix ineffective ras_mask setting due to special asic without sram ecc enable but with poison supported.

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c +1 -0
index d991b3467c47..b85014e7f96b 100644
@@ -3629,6 +3629,7 @@ int amdgpu_ras_is_supported(struct amdgpu_device *adev,
 	     block == AMDGPU_RAS_BLOCK__SDMA ||
 	     block == AMDGPU_RAS_BLOCK__VCN ||
 	     block == AMDGPU_RAS_BLOCK__JPEG) &&
+		(amdgpu_ras_mask & (1 << block)) &&
 	    amdgpu_ras_is_poison_mode_supported(adev) &&
 	    amdgpu_ras_get_ras_block(adev, block, 0))
 		ret = 1;
Signature · 1 line
2.25.1
Reviewed-by on v1 1/1
#1 lore raw

[AMD Official Use Only - General]

Quoted 32 lines

-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Stanley.Yang
Sent: Wednesday, February 21, 2024 10:27 PM
To: [email protected]
Cc: Yang, Stanley <[email protected]>
Subject: [PATCH Review 1/1] drm/amdgpu: Fix ineffective ras_mask settings

Check amdgpu_ras_mask to fix ineffective ras_mask setting due to special asic without sram ecc enable but with poison supported.

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c +1 -0
index d991b3467c47..b85014e7f96b 100644
@@ -3629,6 +3629,7 @@ int amdgpu_ras_is_supported(struct amdgpu_device
 *adev,
           block == AMDGPU_RAS_BLOCK__SDMA ||
           block == AMDGPU_RAS_BLOCK__VCN ||
           block == AMDGPU_RAS_BLOCK__JPEG) &&
+             (amdgpu_ras_mask & (1 << block)) &&
          amdgpu_ras_is_poison_mode_supported(adev) &&
          amdgpu_ras_get_ras_block(adev, block, 0))
              ret = 1;

--
2.25.1