summaryrefslogtreecommitdiff
path: root/drivers/video/fbdev
diff options
context:
space:
mode:
authorYuan Zhao <yzhao@codeaurora.org>2017-10-24 16:21:42 +0800
committerGerrit - the friendly Code Review server <code-review@localhost>2017-11-19 18:44:19 -0800
commit20a606c1281ee308b387fe848dea391c32591561 (patch)
tree3a1eb5f56109f5a1b5fb5a1e5a8d7ab4a5691f65 /drivers/video/fbdev
parentd33ed6b2cc80c5bbe156a1c3efb101f564a4e6ef (diff)
msm: mdss: hdmi: 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. Change-Id: I77a5cd74bc90c249d8902437a7b87a07259a2c35 Signed-off-by: Yuan Zhao <yzhao@codeaurora.org>
Diffstat (limited to 'drivers/video/fbdev')
-rw-r--r--drivers/video/fbdev/msm/mdss_hdmi_panel.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/drivers/video/fbdev/msm/mdss_hdmi_panel.c b/drivers/video/fbdev/msm/mdss_hdmi_panel.c
index a8a56e3a8745..af72973a3988 100644
--- a/drivers/video/fbdev/msm/mdss_hdmi_panel.c
+++ b/drivers/video/fbdev/msm/mdss_hdmi_panel.c
@@ -1,4 +1,4 @@
-/* Copyright (c) 2010-2016, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2010-2017, The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
@@ -632,6 +632,19 @@ static int hdmi_panel_setup_dc(struct hdmi_panel *panel)
vbi_pkt_reg = DSS_REG_R(panel->io, HDMI_VBI_PKT_CTRL);
vbi_pkt_reg |= BIT(5) | BIT(4);
DSS_REG_W(panel->io, HDMI_VBI_PKT_CTRL, vbi_pkt_reg);
+ } else {
+ hdmi_ctrl_reg = DSS_REG_R(panel->io, 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);
+ DSS_REG_W(panel->io, HDMI_CTRL, hdmi_ctrl_reg);
+
+ /* disable the GC packet sending */
+ vbi_pkt_reg = DSS_REG_R(panel->io, HDMI_VBI_PKT_CTRL);
+ vbi_pkt_reg &= ~(BIT(5) | BIT(4));
+ DSS_REG_W(panel->io, HDMI_VBI_PKT_CTRL, vbi_pkt_reg);
}
return rc;