drm/amd/display: Fix windowed MPO video with ODM combine for DCN32
authorSamson Tam <Samson.Tam@amd.com>
Sat, 18 Jun 2022 03:00:30 +0000 (23:00 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 12 Jul 2022 20:50:29 +0000 (16:50 -0400)
commit9dfc3ee1b0f22d9415c9b7c316447d47d4a702d1
tree7c432d9fc45bc80272cf65df8d3d5ffab71b8675
parent149f6d1a6035a7aa6595ac6eeb9c8f566b2103cd
drm/amd/display: Fix windowed MPO video with ODM combine for DCN32

[Why]
In single display configuration, windowed MPO does not work
 with ODM combine.

[How]
For ODM + MPO window on one half of ODM, only 3 pipes should
 be allocated and scaling parameters adjusted to handle this case.
 Otherwise, we use 4 pipes.
Move copy_surface_update_to_plane() before dc_add_plane_to_context()
 so that it gets the updated rect information when setting up
 the pipes.
Add dc_check_boundary_crossing_for_windowed_mpo_with_odm() to force
 a full update when we cross a boundary requiring us to reconfigure
 the number of pipes between 3 and 4 pipes.
Set config.enable_windowed_mpo_odm to true when we have the
 debug.enable_single_display_2to1_odm_policy set to true.
Don't fail validating ODM with windowed MPO if
 config.enable_windowed_mpo_odm is true.

Reviewed-by: Aric Cyr <Aric.Cyr@amd.com>
Acked-by: Solomon Chiu <solomon.chiu@amd.com>
Signed-off-by: Samson Tam <Samson.Tam@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/core/dc.c
drivers/gpu/drm/amd/display/dc/core/dc_resource.c