Skip to contentSkip to conversation

drm/amdgpu: Use correct gfx deferred error count

PATCH In review Xiang Liu 2 participants 2 messages Mar 21, 2025

Subsystems (2)
lore
Share & tools
lore

Xiang Liu

author
#0 lore raw

PATCH 1/1 drm/amdgpu: Use correct gfx deferred error count

In the case of parsing GFX deferred error from SMU corrected error channel, the error count should be set to 1 instead of parsing from MISC0 register, which is 0.

---
 drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c +4 -3
index a58e2ce4deb5..e84238336fb6 100644
@@ -898,9 +898,10 @@ static int gfx_v9_4_3_aca_bank_parser(struct aca_handle *handle,
 		break;
 	case ACA_SMU_TYPE_CE:
 		bank->aca_err_type = ACA_BANK_ERR_CE_DE_DECODE(bank);
-		ret = aca_error_cache_log_bank_error(handle, &info,
-						     bank->aca_err_type,
-						     ACA_REG__MISC0__ERRCNT(misc0));
+		ret = aca_error_cache_log_bank_error(handle, &info, bank->aca_err_type,
+			(bank->aca_err_type == ACA_ERROR_TYPE_CE) ?
+				ACA_REG__MISC0__ERRCNT(misc0) :
+				1);
 		break;
 	default:
 		return -EINVAL;
Signature · 1 line
2.34.1
Reviewed-by on v1 1/1
#1 lore raw

[AMD Official Use Only - AMD Internal Distribution Only]

Regards,
Hawking
-----Original Message-----
From: Liu, Xiang(Dean) <[email protected]>
Sent: Friday, March 21, 2025 20:59
To: [email protected]
Cc: Zhang, Hawking <[email protected]>; Wang, Yang(Kevin) <[email protected]>; Zhou1, Tao <[email protected]>; Chai, Thomas <[email protected]>; Yang, Stanley <[email protected]>; Liu, Xiang(Dean) <[email protected]>
Subject: [PATCH] drm/amdgpu: Use correct gfx deferred error count

In the case of parsing GFX deferred error from SMU corrected error channel, the error count should be set to 1 instead of parsing from MISC0 register, which is 0.

---
 drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c +4 -3
index a58e2ce4deb5..e84238336fb6 100644
@@ -898,9 +898,10 @@ static int gfx_v9_4_3_aca_bank_parser(struct aca_handle *handle,
                break;
        case ACA_SMU_TYPE_CE:
                bank->aca_err_type = ACA_BANK_ERR_CE_DE_DECODE(bank);
-               ret = aca_error_cache_log_bank_error(handle, &info,
-                                                    bank->aca_err_type,
-                                                    ACA_REG__MISC0__ERRCNT(misc0));
+               ret = aca_error_cache_log_bank_error(handle, &info, bank->aca_err_type,
+                       (bank->aca_err_type == ACA_ERROR_TYPE_CE) ?
+                               ACA_REG__MISC0__ERRCNT(misc0) :
+                               1);
                break;
        default:
                return -EINVAL;

--
2.34.1