mirror of
https://github.com/torvalds/linux.git
synced 2026-05-26 16:12:59 +02:00
drm/amd/display: Take emulated dc_sink into account for HDCP
[Why] While updating the config of hdcp, we use the sink_singal type of the dc_sink to decide the HDCP operation mode. However, it doesn't consider the case when the sink is a emulated one. [How] Take dc_em_sink into account while updating HDCP config. 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> Signed-off-by: Wayne Lin <Wayne.Lin@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
84a8b39082
commit
4d31819a37
|
|
@ -448,6 +448,7 @@ 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) {
|
||||
|
|
@ -461,8 +462,13 @@ 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 != NULL)
|
||||
link->mode = mod_hdcp_signal_type_to_operation_mode(aconnector->dc_sink->sink_signal);
|
||||
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);
|
||||
|
||||
display->controller = CONTROLLER_ID_D0 + config->otg_inst;
|
||||
display->dig_fe = config->dig_fe;
|
||||
|
|
@ -473,8 +479,8 @@ static void update_config(void *handle, struct cp_psp_stream_config *config)
|
|||
link->dio_output_id = config->dio_output_idx;
|
||||
link->phy_idx = config->phy_idx;
|
||||
|
||||
link->hdcp_supported_informational = dc_link_is_hdcp14(aconnector->dc_link,
|
||||
aconnector->dc_sink->sink_signal) ? 1 : 0;
|
||||
if (sink)
|
||||
link_is_hdcp14 = dc_link_is_hdcp14(aconnector->dc_link, sink->sink_signal);
|
||||
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;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user