drm/amd/display: always switch off ODM before committing more streams
authorWenjing Liu <wenjing.liu@amd.com>
Tue, 15 Aug 2023 14:47:52 +0000 (10:47 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 30 Aug 2023 19:38:25 +0000 (15:38 -0400)
commitea7e2edca8b2150f945ee25af142fef8438c9944
treeea7518dd1c0fb0bf16b7c74ecc659517c70d7e3f
parent0ee5d7374c99ea306bdfd2c8a1baeda6665b91f5
drm/amd/display: always switch off ODM before committing more streams

ODM power optimization is only supported with single stream. When ODM
power optimization is enabled, we might not have enough free pipes for
enabling other stream. So when we are committing more than 1 stream we
should first switch off ODM power optimization to make room for new
stream and then allocating pipe resource for the new stream.

Cc: stable@vger.kernel.org
Fixes: 59de751e3845 ("drm/amd/display: add ODM case when looking for first split pipe")
Reviewed-by: Dillon Varone <dillon.varone@amd.com>
Acked-by: Hamza Mahfooz <hamza.mahfooz@amd.com>
Signed-off-by: Wenjing Liu <wenjing.liu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/core/dc.c