mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 02:50:49 +09:00
drm/rockchip: dw-dp: don't send sdp when disable video stream
When the display mode change from HDR to SDR but the vsc sdp and
hdr infoframe still send after exit HDR mode, the picture quality
will be abnormal. It need disable sdp when disable video stream.
Fixes: 0ac9316547 ("Revert "drm/rockchip: dw-dp: reset dp controller status"")
Change-Id: I060e8d8e6c9765b71831d08060a1d3ed097bbefa
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
This commit is contained in:
@@ -3857,6 +3857,12 @@ static void dw_dp_link_disable(struct dw_dp *dp)
|
||||
link->train.channel_equalized = false;
|
||||
}
|
||||
|
||||
static void dw_dp_sdp_disalbe(struct dw_dp *dp, int stream_id)
|
||||
{
|
||||
regmap_write(dp->regmap, DPTX_SDP_VERTICAL_CTRL_N(stream_id), 0);
|
||||
regmap_write(dp->regmap, DPTX_SDP_HORIZONTAL_CTRL_N(stream_id), 0);
|
||||
}
|
||||
|
||||
static void dw_dp_mst_encoder_atomic_disable(struct drm_encoder *encoder,
|
||||
struct drm_atomic_state *state)
|
||||
{
|
||||
@@ -3909,6 +3915,7 @@ static void dw_dp_mst_encoder_atomic_disable(struct drm_encoder *encoder,
|
||||
drm_dp_send_power_updown_phy(&dp->mst_mgr, mst_conn->port, false);
|
||||
|
||||
dw_dp_video_disable(dp, mst_enc->stream_id);
|
||||
dw_dp_sdp_disalbe(dp, mst_enc->stream_id);
|
||||
if (!dp->active_mst_links)
|
||||
dw_dp_link_disable(dp);
|
||||
|
||||
@@ -4490,6 +4497,7 @@ static void dw_dp_bridge_atomic_disable(struct drm_bridge *bridge,
|
||||
dw_dp_enable_vop_gate(dp, bridge->encoder->crtc, dp->id, false);
|
||||
dw_dp_hdcp_disable(dp);
|
||||
dw_dp_video_disable(dp, 0);
|
||||
dw_dp_sdp_disalbe(dp, 0);
|
||||
dw_dp_link_disable(dp);
|
||||
bitmap_zero(dp->sdp_reg_bank, SDP_REG_BANK_SIZE);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user