]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
drm/amd/display: limit clear_update_flags to dcn32 and above
authorCharlene Liu <Charlene.Liu@amd.com>
Thu, 26 Jun 2025 20:36:17 +0000 (16:36 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 20 Aug 2025 16:41:08 +0000 (18:41 +0200)
[ Upstream commit f354556e29f40ef44fa8b13dc914817db3537e20 ]

[why]
dc has some code out of sync:
dc_commit_updates_for_stream handles v1/v2/v3,
but dc_update_planes_and_stream makes v1 asic to use v2.

as a reression fix: limit clear_update_flags to dcn32 or newer asic.
need to follow up that v1 asic using v2 issue.

Reviewed-by: Syed Hassan <syed.hassan@amd.com>
Signed-off-by: Charlene Liu <Charlene.Liu@amd.com>
Signed-off-by: Ivan Lipski <ivan.lipski@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/amd/display/dc/core/dc.c

index b34b5b52236dce4b4c9270b175908c8d7c673497..3dd7e2b6d5300c43c8d56e3c3927dcec18102dfa 100644 (file)
@@ -5439,8 +5439,7 @@ bool dc_update_planes_and_stream(struct dc *dc,
        else
                ret = update_planes_and_stream_v2(dc, srf_updates,
                        surface_count, stream, stream_update);
-
-       if (ret)
+       if (ret && dc->ctx->dce_version >= DCN_VERSION_3_2)
                clear_update_flags(srf_updates, surface_count, stream);
 
        return ret;
@@ -5471,7 +5470,7 @@ void dc_commit_updates_for_stream(struct dc *dc,
                ret = update_planes_and_stream_v1(dc, srf_updates, surface_count, stream,
                                stream_update, state);
 
-       if (ret)
+       if (ret && dc->ctx->dce_version >= DCN_VERSION_3_2)
                clear_update_flags(srf_updates, surface_count, stream);
 }