From 7c00e5859b3bd232b2eceaafad4067fbfa46aeca Mon Sep 17 00:00:00 2001 From: Le Ma Date: Thu, 7 May 2026 19:38:44 +0800 Subject: [PATCH] drm/amdgpu: disable GFX clockgating for GC 12.1.0 RLC fw disables GFX CGCG and CGLS on GC 12.1.0 by default, so clear the corresponding CG flags and keep GUI idle interrupts disabled during gfx init. Signed-off-by: Le Ma Reviewed-by: Hawking Zhang Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v12_1.c | 5 ++--- drivers/gpu/drm/amd/amdgpu/soc_v1_0.c | 3 +-- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v12_1.c b/drivers/gpu/drm/amd/amdgpu/gfx_v12_1.c index 41b92d068517..123fb904f4bf 100644 --- a/drivers/gpu/drm/amd/amdgpu/gfx_v12_1.c +++ b/drivers/gpu/drm/amd/amdgpu/gfx_v12_1.c @@ -2754,9 +2754,8 @@ static int gfx_v12_1_xcc_cp_resume(struct amdgpu_device *adev, uint16_t xcc_mask return r; } - /* GFX CGCG and LS is set by default */ - if (adev->firmware.load_type == AMDGPU_FW_LOAD_PSP) - gfx_v12_1_xcc_enable_gui_idle_interrupt(adev, true, xcc_id); + /* GFX CGCG and LS is disabled by rlc fw */ + gfx_v12_1_xcc_enable_gui_idle_interrupt(adev, false, xcc_id); gfx_v12_1_xcc_cp_set_doorbell_range(adev, xcc_id); diff --git a/drivers/gpu/drm/amd/amdgpu/soc_v1_0.c b/drivers/gpu/drm/amd/amdgpu/soc_v1_0.c index 15923d2e05a5..8a1365ae9db6 100644 --- a/drivers/gpu/drm/amd/amdgpu/soc_v1_0.c +++ b/drivers/gpu/drm/amd/amdgpu/soc_v1_0.c @@ -293,8 +293,7 @@ static int soc_v1_0_common_early_init(struct amdgpu_ip_block *ip_block) switch (amdgpu_ip_version(adev, GC_HWIP, 0)) { case IP_VERSION(12, 1, 0): - adev->cg_flags = AMD_CG_SUPPORT_GFX_CGCG | - AMD_CG_SUPPORT_GFX_CGLS; + adev->cg_flags = 0; adev->pg_flags = AMD_PG_SUPPORT_VCN_DPG; adev->external_rev_id = adev->rev_id + 0x50; break;