]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
drm/amd/display: Block dynamic IPS2 on DCN35 for incompatible FW versions
authorNicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Tue, 27 Aug 2024 18:13:10 +0000 (14:13 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 4 Oct 2024 14:33:29 +0000 (16:33 +0200)
commit 401c90c4d64f2227fc2f4c02d2ad23296bf5ca6f upstream.

[WHY]
Hangs with Z8 can occur if running an older unfixed PMFW version.

[HOW]
Fallback to RCG only for dynamic IPS2 states if it's not newer than
93.12. Limit to DCN35.

Cc: Mario Limonciello <mario.limonciello@amd.com>
Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
Reviewed-by: Charlene Liu <charlene.liu@amd.com>
Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Signed-off-by: Alex Hung <alex.hung@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/drm/amd/display/dc/clk_mgr/dcn35/dcn35_clk_mgr.c

index 6c9b4e6491a5e45e349954bf0bfc6aeaf6bd87fc..985e847f9580324e106f221db9ad4671f9333002 100644 (file)
@@ -1149,6 +1149,12 @@ void dcn35_clk_mgr_construct(
                        ctx->dc->debug.disable_dpp_power_gate = false;
                        ctx->dc->debug.disable_hubp_power_gate = false;
                        ctx->dc->debug.disable_dsc_power_gate = false;
+
+                       /* Disable dynamic IPS2 in older PMFW (93.12) for Z8 interop. */
+                       if (ctx->dc->config.disable_ips == DMUB_IPS_ENABLE &&
+                           ctx->dce_version == DCN_VERSION_3_5 &&
+                           ((clk_mgr->base.smu_ver & 0x00FFFFFF) <= 0x005d0c00))
+                               ctx->dc->config.disable_ips = DMUB_IPS_RCG_IN_ACTIVE_IPS2_IN_OFF;
                } else {
                        /*let's reset the config control flag*/
                        ctx->dc->config.disable_ips = DMUB_IPS_DISABLE_ALL; /*pmfw not support it, disable it all*/