drm/amd/display: fix underflow in some two display subvp/non-subvp configs
authorSamson Tam <samson.tam@amd.com>
Fri, 15 Mar 2024 20:19:21 +0000 (16:19 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 10 Apr 2024 01:51:25 +0000 (21:51 -0400)
commit7ae0caf348830d92661296ec46ec5b4cfeb440b2
tree8f1c9cc325fad7b06f19bb11c9b4e743fca076b8
parent4df96ba66760345471a85ef7bb29e1cd4e956057
drm/amd/display: fix underflow in some two display subvp/non-subvp configs

[Why]
In two display configuration, switching between subvp and non-subvp
 may cause underflow because it moves an existing pipe between
 displays

[How]
Create helper function for applying pipe split flags
Apply pipe split flags prior to deciding on subvp
During subvp check, do not merge pipes, so it can retain previous
 pipe configuration
Add check for prev odm pipe in subvp check
For single display subvp case, use same odm policy for phantom pipes
 as main subvp pipe

Reviewed-by: Alvin Lee <alvin.lee2@amd.com>
Acked-by: Roman Li <roman.li@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/dml/dcn32/dcn32_fpu.c
drivers/gpu/drm/amd/display/dc/resource/dcn32/dcn32_resource.c