rk3036 hdmi: fix hdmi display error when TV power down and power up
[firefly-linux-kernel-4.4.55.git] / drivers / video / rockchip / hdmi / rk_hdmi_edid.c
index fa90f96bb84c39389cf8ceeb868f5e63b3a7c75a..7921c8f5e11a603309e08e1bf86471d29701918e 100755 (executable)
@@ -94,7 +94,10 @@ static int hdmi_edid_parse_dtd(unsigned char *block, struct fb_videomode *mode)
 static int hdmi_edid_parse_base(unsigned char *buf, int *extend_num,
                                struct hdmi_edid *pedid)
 {
-       int rc, i;
+       int rc;
+#ifdef DEBUG
+       int i = 0;
+#endif
 
        if (buf == NULL || extend_num == NULL)
                return E_HDMI_EDID_PARAM;
@@ -220,6 +223,10 @@ static int hdmi_edid_parse_cea_sdb(unsigned char *buf, struct hdmi_edid *pedid)
        if (IEEEOUI == 0x0c03)
                pedid->sink_hdmi = 1;
 
+       pedid->cecaddress = buf[cur_offset + 5];
+       pedid->cecaddress |= buf[cur_offset + 4] << 8;
+       hdmi_edid_debug("[EDID-CEA] CEC Physical addres is 0x%08x.\n", pedid->cecaddress);
+
        if (count > 5) {
                pedid->deepcolor = (buf[6] >> 3) & 0x0F;
                supports_ai = buf[6] >> 7;