drm/amdgpu: Remove redundant calls of ras_late_init in hdp ras block
authoryipechai <YiPeng.Chai@amd.com>
Mon, 14 Feb 2022 06:17:19 +0000 (14:17 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 17 Feb 2022 20:59:04 +0000 (15:59 -0500)
Remove redundant calls of ras_late_init in hdp ras block.

Signed-off-by: yipechai <YiPeng.Chai@amd.com>
Reviewed-by: Tao Zhou <tao.zhou1@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
drivers/gpu/drm/amd/amdgpu/amdgpu_hdp.c
drivers/gpu/drm/amd/amdgpu/hdp_v4_0.c

index 092263b..bf0cc51 100644 (file)
@@ -470,7 +470,7 @@ int amdgpu_gmc_ras_late_init(struct amdgpu_device *adev)
        }
 
        if (adev->hdp.ras && adev->hdp.ras->ras_block.ras_late_init) {
-               r = adev->hdp.ras->ras_block.ras_late_init(adev, NULL);
+               r = adev->hdp.ras->ras_block.ras_late_init(adev, adev->hdp.ras_if);
                if (r)
                        return r;
        }
index 70a0961..b7fbc11 100644 (file)
 #include "amdgpu.h"
 #include "amdgpu_ras.h"
 
-int amdgpu_hdp_ras_late_init(struct amdgpu_device *adev, struct ras_common_if *ras_block)
-{
-       return amdgpu_ras_block_late_init(adev, adev->hdp.ras_if);
-}
-
 void amdgpu_hdp_ras_fini(struct amdgpu_device *adev)
 {
        if (amdgpu_ras_is_supported(adev, AMDGPU_RAS_BLOCK__HDP) &&
index a9ed423..c9e931f 100644 (file)
@@ -163,7 +163,7 @@ struct amdgpu_hdp_ras hdp_v4_0_ras = {
                        .type = AMDGPU_RAS_ERROR__MULTI_UNCORRECTABLE,
                },
                .hw_ops = &hdp_v4_0_ras_hw_ops,
-               .ras_late_init = amdgpu_hdp_ras_late_init,
+               .ras_late_init = amdgpu_ras_block_late_init,
                .ras_fini = amdgpu_hdp_ras_fini,
        },
 };