diff options
author | Wayne Lin <Wayne.Lin@amd.com> | 2022-04-13 15:52:48 +0800 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2022-06-21 18:17:22 -0400 |
commit | 10a36226157035e84aaa58e1699a32b3de2755af (patch) | |
tree | a40f5fb42edc0b083c5101a8c118df63fca8a5be /drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_hdcp.c | |
parent | 4dd905fd9429626937107ca13770aa836c8a7e6e (diff) |
drm/amd/display: Revert "drm/amd/display: Add flag to detect dpms force off during HPD"
This reverts commit 035f54969bb2c1a5ced52f43e4ef393e0c0f6bfa.
The reverted commit was trying to fix side effect brought by
commit 3c4d55c9b9be ("drm/amd/display: turn DPMS off on connector unplug")
However,
* This reverted commit will have mst case never call dm_set_dpms_off()
which conflicts the idea of original commit 3c4d55c9b9be ("drm/amd/display: turn DPMS off on connector unplug")
That's due to dm_crtc_state is always null since the input parameter
aconnector is the root device (source) of mst topology. It's not an
end stream sink within the mst topology.
* Setting dpms off should be triggered by usermode. Besdies, it seems
usermode does release relevant resource for mst & non-mst case when
unplug connecotr now. Which means we no longer need both commits now:
commit 3c4d55c9b9be ("drm/amd/display: turn DPMS off on connector unplug")
commit 035f54969bb2 ("drm/amd/display: Add flag to detect dpms force off during HPD")
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Reviewed-by: Aurabindo Jayamohanan Pillai <Aurabindo.Pillai@amd.com>
Acked-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Acked-by: Lyude Paul <lyude@redhat.com>
Signed-off-by: Wayne Lin <Wayne.Lin@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_hdcp.c')
-rw-r--r-- | drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_hdcp.c | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_hdcp.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_hdcp.c index fcafe07ed908..a4191b2b4c65 100644 --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_hdcp.c +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_hdcp.c @@ -448,7 +448,6 @@ static void update_config(void *handle, struct cp_psp_stream_config *config) struct mod_hdcp_display *display = &hdcp_work[link_index].display; struct mod_hdcp_link *link = &hdcp_work[link_index].link; struct drm_connector_state *conn_state; - struct dc_sink *sink = NULL; bool link_is_hdcp14 = false; if (config->dpms_off) { @@ -462,13 +461,8 @@ static void update_config(void *handle, struct cp_psp_stream_config *config) display->index = aconnector->base.index; display->state = MOD_HDCP_DISPLAY_ACTIVE; - if (aconnector->dc_sink) - sink = aconnector->dc_sink; - else if (aconnector->dc_em_sink) - sink = aconnector->dc_em_sink; - - if (sink != NULL) - link->mode = mod_hdcp_signal_type_to_operation_mode(sink->sink_signal); + if (aconnector->dc_sink != NULL) + link->mode = mod_hdcp_signal_type_to_operation_mode(aconnector->dc_sink->sink_signal); display->controller = CONTROLLER_ID_D0 + config->otg_inst; display->dig_fe = config->dig_fe; @@ -478,8 +472,9 @@ static void update_config(void *handle, struct cp_psp_stream_config *config) link->link_enc_idx = config->link_enc_idx; link->dio_output_id = config->dio_output_idx; link->phy_idx = config->phy_idx; - if (sink) - link_is_hdcp14 = dc_link_is_hdcp14(aconnector->dc_link, sink->sink_signal); + + link->hdcp_supported_informational = dc_link_is_hdcp14(aconnector->dc_link, + aconnector->dc_sink->sink_signal) ? 1 : 0; link->hdcp_supported_informational = link_is_hdcp14; link->dp.rev = aconnector->dc_link->dpcd_caps.dpcd_rev.raw; link->dp.assr_enabled = config->assr_enabled; |