aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/display/intel_dp_mst.c
diff options
context:
space:
mode:
authorImre Deak <imre.deak@intel.com>2023-10-24 04:09:17 +0300
committerImre Deak <imre.deak@intel.com>2023-11-08 17:22:18 +0200
commit503611c8a08ab660c718c295d26180e585058d95 (patch)
tree34599416182002123010852862587223115d7f30 /drivers/gpu/drm/i915/display/intel_dp_mst.c
parentdrm/i915/dp_mst: Handle the Synaptics HBlank expansion quirk (diff)
downloadlinux-503611c8a08ab660c718c295d26180e585058d95.tar.gz
linux-503611c8a08ab660c718c295d26180e585058d95.zip
drm/i915/dp_mst: Enable decompression in the sink from the MST encoder hooks
Enable/disable the DSC decompression in the sink/branch from the MST encoder hooks. This prepares for an upcoming patch toggling DSC for each stream as needed, but for now keeps the current behavior, as DSC is only enabled for the first MST stream. v2: - Rebased on latest drm-tip. Reviewed-by: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20231107001505.3370108-5-imre.deak@intel.com
Diffstat (limited to 'drivers/gpu/drm/i915/display/intel_dp_mst.c')
-rw-r--r--drivers/gpu/drm/i915/display/intel_dp_mst.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/display/intel_dp_mst.c b/drivers/gpu/drm/i915/display/intel_dp_mst.c
index 4f066a868b9a..eab69f57655d 100644
--- a/drivers/gpu/drm/i915/display/intel_dp_mst.c
+++ b/drivers/gpu/drm/i915/display/intel_dp_mst.c
@@ -776,6 +776,13 @@ static void intel_mst_disable_dp(struct intel_atomic_state *state,
intel_hdcp_disable(intel_mst->connector);
intel_audio_codec_disable(encoder, old_crtc_state, old_conn_state);
+
+ if (intel_dp->active_mst_links == 1) /* last stream ? */
+ /*
+ * TODO: disable decompression for all streams/in any MST ports, not
+ * only in the first downstream branch device.
+ */
+ intel_dp_sink_set_decompression_state(intel_dp, old_crtc_state, false);
}
static void intel_mst_post_disable_dp(struct intel_atomic_state *state,
@@ -932,9 +939,15 @@ static void intel_mst_pre_enable_dp(struct intel_atomic_state *state,
drm_dp_send_power_updown_phy(&intel_dp->mst_mgr, connector->port, true);
- if (first_mst_stream)
+ if (first_mst_stream) {
+ /*
+ * TODO: enable decompression for all streams/in any MST ports, not
+ * only in the first downstream branch device.
+ */
+ intel_dp_sink_set_decompression_state(intel_dp, pipe_config, true);
dig_port->base.pre_enable(state, &dig_port->base,
pipe_config, NULL);
+ }
intel_dp->active_mst_links++;