diff options
| author | Abhinav Kumar <abhinavk@codeaurora.org> | 2017-10-20 20:43:23 -0700 |
|---|---|---|
| committer | Abhinav Kumar <abhinavk@codeaurora.org> | 2017-10-24 01:36:18 -0700 |
| commit | 45a00766745283f6956d2d418e6bf8e58cc52487 (patch) | |
| tree | 9a029675dba8ca0779b3e4e459eecdc123dec142 | |
| parent | 9551e129dd2625ea2ab4fa5620820849b069ce2f (diff) | |
drm/msm: clear deep color bits in the HDMI controller
Clear the deep color bits in the HDMI controller in case
the mode does not need OR support deep color.
Otherwise it causes issues while switching across modes where
the sink supports deep color in one of the modes but not in the
other.
Change-Id: I8accf00e89868ccaa781a3f18eb9a662d9c9235c
Signed-off-by: Abhinav Kumar <abhinavk@codeaurora.org>
| -rw-r--r-- | drivers/gpu/drm/msm/hdmi-staging/sde_hdmi_bridge.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/gpu/drm/msm/hdmi-staging/sde_hdmi_bridge.c b/drivers/gpu/drm/msm/hdmi-staging/sde_hdmi_bridge.c index 0d93edb9201f..8cb17b13838b 100644 --- a/drivers/gpu/drm/msm/hdmi-staging/sde_hdmi_bridge.c +++ b/drivers/gpu/drm/msm/hdmi-staging/sde_hdmi_bridge.c @@ -435,6 +435,19 @@ static void _sde_hdmi_bridge_setup_deep_color(struct hdmi *hdmi) vbi_pkt_reg = hdmi_read(hdmi, REG_HDMI_VBI_PKT_CTRL); vbi_pkt_reg |= BIT(5) | BIT(4); hdmi_write(hdmi, REG_HDMI_VBI_PKT_CTRL, vbi_pkt_reg); + } else { + hdmi_ctrl_reg = hdmi_read(hdmi, REG_HDMI_CTRL); + + /* disable GC CD override */ + hdmi_ctrl_reg &= ~BIT(27); + /* disable deep color for RGB888/YUV444/YUV420 30 bits */ + hdmi_ctrl_reg &= ~BIT(24); + hdmi_write(hdmi, REG_HDMI_CTRL, hdmi_ctrl_reg); + + /* disable the GC packet sending */ + vbi_pkt_reg = hdmi_read(hdmi, REG_HDMI_VBI_PKT_CTRL); + vbi_pkt_reg &= ~(BIT(5) | BIT(4)); + hdmi_write(hdmi, REG_HDMI_VBI_PKT_CTRL, vbi_pkt_reg); } } |
