drm/amd/display: Change frontend/backend programming sequence
authorLeo (Sunpeng) Li <sunpeng.li@amd.com>
Tue, 7 Nov 2017 18:51:02 +0000 (13:51 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 6 Dec 2017 17:47:40 +0000 (12:47 -0500)
commitb674f1edc9a033f4d3ea61e5f4996186e27bdcb5
tree2977e070094d831162b048c0af2bc4a07490d9ac
parent4faf6eddfbebba1cdc4653484b7a8c8f28bd3bff
drm/amd/display: Change frontend/backend programming sequence

This is a follow-up to the following change:

Yongqiang Sun: Program front end first when set mode.

Due to pipe-splitting features, how we handle stream enabling and
disabling needs to change.

In the case of pipe split disable, two planes need to be combined back
into the same stream. This needs to be done before any stream
programming happens.

The previous patch addresses this, but breaks cross-platform
compatibility. It's not guaranteed that a dc commit will be called
separately to program planes and streams.

Therefore, we handle the combined commit case by doing plane programming
both before and after stream programming, to handle pipe split disable
and plane enable respectively.

Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com>
Acked-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/core/dc.c