drm/amd/display: Adjust the MST resume flow
authorWayne Lin <wayne.lin@amd.com>
Tue, 22 Aug 2023 08:03:17 +0000 (16:03 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 11 Sep 2023 22:21:50 +0000 (18:21 -0400)
commitec5fa9fcdeca69edf7dab5ca3b2e0ceb1c08fe9a
treed647e9e9e2c7058fb49f7afd7403019cd155633f
parentffd6bde302061aeee405ab364403af30210f0b99
drm/amd/display: Adjust the MST resume flow

[Why]
In drm_dp_mst_topology_mgr_resume() today, it will resume the
mst branch to be ready handling mst mode and also consecutively do
the mst topology probing. Which will cause the dirver have chance
to fire hotplug event before restoring the old state. Then Userspace
will react to the hotplug event based on a wrong state.

[How]
Adjust the mst resume flow as:
1. set dpcd to resume mst branch status
2. restore source old state
3. Do mst resume topology probing

For drm_dp_mst_topology_mgr_resume(), it's better to adjust it to
pull out topology probing work into a 2nd part procedure of the mst
resume. Will have a follow up patch in drm.

Reviewed-by: Chao-kai Wang <stylon.wang@amd.com>
Cc: Mario Limonciello <mario.limonciello@amd.com>
Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
Acked-by: Stylon Wang <stylon.wang@amd.com>
Signed-off-by: Wayne Lin <wayne.lin@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c