Commit 69bf42fb authored by Yang Wang's avatar Yang Wang Committed by Alex Deucher

drm/amdgpu: refine aca error cache for umc v12.0

refine aca error cache for umc v12.0
Signed-off-by: default avatarYang Wang <kevinyang.wang@amd.com>
Reviewed-by: default avatarHawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 87428b40
...@@ -508,10 +508,11 @@ static int umc_v12_0_aca_bank_generate_report(struct aca_handle *handle, struct ...@@ -508,10 +508,11 @@ static int umc_v12_0_aca_bank_generate_report(struct aca_handle *handle, struct
struct aca_bank_report *report, void *data) struct aca_bank_report *report, void *data)
{ {
struct amdgpu_device *adev = handle->adev; struct amdgpu_device *adev = handle->adev;
struct aca_bank_info info;
u64 status; u64 status;
int ret; int ret;
ret = aca_bank_info_decode(bank, &report->info); ret = aca_bank_info_decode(bank, &info);
if (ret) if (ret)
return ret; return ret;
...@@ -519,12 +520,18 @@ static int umc_v12_0_aca_bank_generate_report(struct aca_handle *handle, struct ...@@ -519,12 +520,18 @@ static int umc_v12_0_aca_bank_generate_report(struct aca_handle *handle, struct
switch (type) { switch (type) {
case ACA_SMU_TYPE_UE: case ACA_SMU_TYPE_UE:
if (umc_v12_0_is_uncorrectable_error(adev, status)) { if (umc_v12_0_is_uncorrectable_error(adev, status)) {
report->count[ACA_ERROR_TYPE_UE] = 1; ret = aca_error_cache_log_bank_error(handle, &info, ACA_ERROR_TYPE_UE,
1ULL);
if (ret)
return ret;
} }
break; break;
case ACA_SMU_TYPE_CE: case ACA_SMU_TYPE_CE:
if (umc_v12_0_is_correctable_error(adev, status)) { if (umc_v12_0_is_correctable_error(adev, status)) {
report->count[ACA_ERROR_TYPE_CE] = 1; ret = aca_error_cache_log_bank_error(handle, &info, ACA_ERROR_TYPE_UE,
1ULL);
if (ret)
return ret;
} }
break; break;
default: default:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment