Commit b04fa59a authored by JeromeHong's avatar JeromeHong Committed by Alex Deucher

drm/amd/display: Avoid force minimal transaction in case of surface_count equal to 0

[why]
Call commit_minimal_transition_state wrongly in case of surface_count
equal to 0.

[how]
Add a condition to filter case of surface_count equal to 0.
Tested-by: default avatarDaniel Wheeler <daniel.wheeler@amd.com>
Reviewed-by: default avatarAric Cyr <Aric.Cyr@amd.com>
Acked-by: default avatarPavle Kotarac <Pavle.Kotarac@amd.com>
Signed-off-by: default avatarJeromeHong <jerome.hong@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 34955a1e
...@@ -3625,6 +3625,7 @@ bool dc_update_planes_and_stream(struct dc *dc, ...@@ -3625,6 +3625,7 @@ bool dc_update_planes_and_stream(struct dc *dc,
dc->current_state->stream_count > 0 && dc->current_state->stream_count > 0 &&
dc->debug.pipe_split_policy != MPC_SPLIT_AVOID) { dc->debug.pipe_split_policy != MPC_SPLIT_AVOID) {
/* determine if minimal transition is required */ /* determine if minimal transition is required */
if (surface_count > 0) {
if (cur_stream_status->plane_count > surface_count) { if (cur_stream_status->plane_count > surface_count) {
force_minimal_pipe_splitting = true; force_minimal_pipe_splitting = true;
} else if (cur_stream_status->plane_count < surface_count) { } else if (cur_stream_status->plane_count < surface_count) {
...@@ -3632,6 +3633,7 @@ bool dc_update_planes_and_stream(struct dc *dc, ...@@ -3632,6 +3633,7 @@ bool dc_update_planes_and_stream(struct dc *dc,
is_plane_addition = true; is_plane_addition = true;
} }
} }
}
/* on plane addition, minimal state is the current one */ /* on plane addition, minimal state is the current one */
if (force_minimal_pipe_splitting && is_plane_addition && if (force_minimal_pipe_splitting && is_plane_addition &&
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment