drm/amdgpu: drop duplicated ecc check for vega10 (v4)
Subsystems (2)
PATCH 1/1 drm/amdgpu: drop duplicated ecc check for vega10 (v4)
The same ECC check has been executed in amdgpu_ras_init for vega10, prior to gmc_v9_0_late_init.
v2: drop all atombios helper callings
v3: use bit operation
v4: correct inline comment, remove parity check statement
--- drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-)
drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c +7 -12
@@ -1193,21 +1193,16 @@ static int gmc_v9_0_late_init(void *handle) r =amdgpu_gmc_allocate_vm_inv_eng (adev);if (r)return r; -/* Check if ecc is available */ + +/* +* Workaround performance drop issue with VBIOS enables partial +* writes, while disables HBM ECC for vega10. +*/ if (!amdgpu_sriov_vf (adev) && (adev->asic_type ==CHIP_VEGA10 )) { - r =amdgpu_atomfirmware_mem_ecc_supported (adev); -if (!r) { -DRM_INFO ("ECC is not present.\n" ); + if (!(adev->ras_features & (1 << AMDGPU_RAS_BLOCK__UMC)) {if (adev->df.funcs->enable_ecc_force_par_wr_rmw) adev->df.funcs->enable_ecc_force_par_wr_rmw (adev, false); - }else -DRM_INFO ("ECC is active.\n" ); - - r =amdgpu_atomfirmware_sram_ecc_supported (adev); -if (!r) -DRM_INFO ("SRAM ECC is not present.\n" ); -else -DRM_INFO ("SRAM ECC is active.\n" ); + } }if (adev->mmhub.funcs && adev->mmhub.funcs->reset_ras_error_count)
Signature · 6 lines
2.17.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
[AMD Public Use]
Series is
Regards,
Hawking
-----Original Message-----
From: Chen, Guchun <[email protected]>
Sent: Wednesday, September 30, 2020 12:38
To: [email protected]; Deucher, Alexander <[email protected]>; Zhang, Hawking <[email protected]>; Li, Dennis <[email protected]>; Zhou1, Tao <[email protected]>; Clements, John <[email protected]>
Cc: Chen, Guchun <[email protected]>
Subject: [PATCH] drm/amdgpu: drop duplicated ecc check for vega10 (v4)
The same ECC check has been executed in amdgpu_ras_init for vega10, prior to gmc_v9_0_late_init.
v2: drop all atombios helper callings
v3: use bit operation
v4: correct inline comment, remove parity check statement
--- drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-)
drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c +7 -12
@@ -1193,21 +1193,16 @@ static int gmc_v9_0_late_init(void *handle) r =amdgpu_gmc_allocate_vm_inv_eng (adev);if (r)return r; -/* Check if ecc is available */ + +/* +* Workaround performance drop issue with VBIOS enables partial +* writes, while disables HBM ECC for vega10. +*/ if (!amdgpu_sriov_vf (adev) && (adev->asic_type ==CHIP_VEGA10 )) { - r =amdgpu_atomfirmware_mem_ecc_supported (adev); -if (!r) { -DRM_INFO ("ECC is not present.\n" ); + if (!(adev->ras_features & (1 << AMDGPU_RAS_BLOCK__UMC)) {if (adev->df.funcs->enable_ecc_force_par_wr_rmw) adev->df.funcs->enable_ecc_force_par_wr_rmw (adev, false); - }else -DRM_INFO ("ECC is active.\n" ); - - r =amdgpu_atomfirmware_sram_ecc_supported (adev); -if (!r) -DRM_INFO ("SRAM ECC is not present.\n" ); -else -DRM_INFO ("SRAM ECC is active.\n" ); + } }if (adev->mmhub.funcs && adev->mmhub.funcs->reset_ras_error_count)
--
2.17.1
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx