drm/amd/display: remove ODM combine before bandwidth validation
authorWenjing Liu <wenjing.liu@amd.com>
Tue, 28 May 2024 20:52:15 +0000 (16:52 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 14 Jun 2024 20:17:16 +0000 (16:17 -0400)
[why]
DML1 validation code doesn't have the ability to remove ODM combine.
It will directly translate currently used ODM combine config into ODM
override. If ODM combine is used in the initial state it will only
validate the timing if ODM is used. This is not correct for dynamic ODM u
se case, as ODM is used as an optimization not a hard requirement.

[how]
Remove ODM combine in the initial state before bandwidth validation so
DML will not translate it into ODM override in the initial bandwidth
validation.

Reviewed-by: Dillon Varone <dillon.varone@amd.com>
Acked-by: Zaeem Mohamed <zaeem.mohamed@amd.com>
Signed-off-by: Wenjing Liu <wenjing.liu@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/dml/dcn32/dcn32_fpu.c

index 194422dd979d81492669c3fc929c15860cf4eda1..5ef10e2b9443a34e7431f27f5f93ae5087f40cc4 100644 (file)
@@ -2154,6 +2154,8 @@ bool dcn32_internal_validate_bw(struct dc *dc,
 
        dc->res_pool->funcs->update_soc_for_wm_a(dc, context);
 
+       for (i = 0; i < context->stream_count; i++)
+               resource_update_pipes_for_stream_with_slice_count(context, dc->current_state, dc->res_pool, context->streams[i], 1);
        pipe_cnt = dc->res_pool->funcs->populate_dml_pipes(dc, context, pipes, fast_validate);
 
        if (!pipe_cnt) {