drm/amdgpu: support pcie bif ras query and inject
authorGuchun Chen <guchun.chen@amd.com>
Wed, 11 Sep 2019 03:07:15 +0000 (11:07 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 16 Sep 2019 15:09:30 +0000 (10:09 -0500)
Call pcie bif ras query/inject in amdgpu ras.

Signed-off-by: Tao Zhou <tao.zhou1@amd.com>
Signed-off-by: Guchun Chen <guchun.chen@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c

index 994d2b34094c7d347f0ec136361120ecef417136..faf6863ca78507d34f2ad86a148d074bf8fef7a6 100644 (file)
@@ -656,6 +656,10 @@ int amdgpu_ras_error_query(struct amdgpu_device *adev,
                if (adev->mmhub_funcs->query_ras_error_count)
                        adev->mmhub_funcs->query_ras_error_count(adev, &err_data);
                break;
+       case AMDGPU_RAS_BLOCK__PCIE_BIF:
+               if (adev->nbio.funcs->query_ras_error_count)
+                       adev->nbio.funcs->query_ras_error_count(adev, &err_data);
+               break;
        default:
                break;
        }
@@ -705,6 +709,7 @@ int amdgpu_ras_error_inject(struct amdgpu_device *adev,
        case AMDGPU_RAS_BLOCK__UMC:
        case AMDGPU_RAS_BLOCK__MMHUB:
        case AMDGPU_RAS_BLOCK__XGMI_WAFL:
+       case AMDGPU_RAS_BLOCK__PCIE_BIF:
                ret = psp_ras_trigger_error(&adev->psp, &block_info);
                break;
        default: