From: Oak Zeng Date: Thu, 6 May 2021 16:24:17 +0000 (-0500) Subject: drm/amdgpu: Quit RAS initialization earlier if RAS is disabled X-Git-Tag: accepted/tizen/unified/20230118.172025~6864^2~24^2~38 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7ddd9770857e26e6c284475260afce2fe71b4cb5;p=platform%2Fkernel%2Flinux-rpi.git drm/amdgpu: Quit RAS initialization earlier if RAS is disabled If RAS is disabled through amdgpu_ras_enable kernel parameter, we should quit the RAS initialization eariler to avoid initialization of some RAS data structure such as sysfs etc. Reviewed-by: Hawking Zhang Signed-off-by: Oak Zeng Signed-off-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c index 609530c..a94be18 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c @@ -2151,7 +2151,7 @@ int amdgpu_ras_init(struct amdgpu_device *adev) amdgpu_ras_check_supported(adev); - if (!adev->ras_hw_enabled || adev->asic_type == CHIP_VEGA10) { + if (!adev->ras_enabled || adev->asic_type == CHIP_VEGA10) { /* set gfx block ras context feature for VEGA20 Gaming * send ras disable cmd to ras ta during ras late init. */