rk hdmi: update hdmi connect status
authorhjc <hjc@rock-chips.com>
Fri, 10 Oct 2014 07:11:31 +0000 (15:11 +0800)
committerhjc <hjc@rock-chips.com>
Sat, 11 Oct 2014 06:06:23 +0000 (14:06 +0800)
drivers/video/rockchip/hdmi/rk_hdmi.h
drivers/video/rockchip/hdmi/rk_hdmi_task.c

index d13bed5da6373c6fb3dd553066b22eb6ed1f7c59..c853654871a5c3693482baa353e258a7a49d95b2 100755 (executable)
@@ -364,7 +364,6 @@ struct hdmi {
        int tmdsclk;            /* TDMS Clock frequency */
        int pixclock;           /* Pixel Clcok frequency */
        int uboot_logo;
-       int uboot_vic;
 
        struct list_head pwrlist_head;
 
index 174a19127af66264f35d891ceb127912bd2bb820..4311edf9c7a3c5aecbf5b72d0d81738dcccea984 100755 (executable)
@@ -9,7 +9,7 @@
 #define HDMI_MAX_ID 1
 
 static char *envp[] = { "INTERFACE=HDMI", NULL };
-static int uboot_vic;
+static int uboot_vic=-1;
 static void hdmi_sys_show_state(struct hdmi *hdmi)
 {
        switch (hdmi->state) {
@@ -49,8 +49,7 @@ static void hdmi_sys_show_state(struct hdmi *hdmi)
 int hdmi_sys_init(struct hdmi *hdmi)
 {
        hdmi->uboot_logo = support_uboot_display();
-       printk("%s,uboot-logo=%d,uboot_vic=%d\n",__func__,hdmi->uboot_logo,uboot_vic);
-       if (hdmi->uboot_logo) {
+       if ((uboot_vic > 0) && (hdmi->uboot_logo > 0)) {
                hdmi->hotplug = HDMI_HPD_ACTIVED;
                hdmi->state = PLAY_BACK;
                hdmi->enable = HDMI_ENABLE;
@@ -62,7 +61,9 @@ int hdmi_sys_init(struct hdmi *hdmi)
                hdmi->enable = HDMI_ENABLE;
                hdmi->display = HDMI_DISABLE;
                hdmi->vic = HDMI_VIDEO_DEFAULT_MODE;
+               hdmi->uboot_logo = 0;
        }
+       hdmi_dbg(hdmi->dev, "uboot-logo=%d,uboot_vic=%d\n",hdmi->uboot_logo,uboot_vic);
        hdmi->autoconfig = HDMI_AUTO_CONFIGURE;
        hdmi->audio.channel = HDMI_AUDIO_DEFAULT_CHANNEL;
        hdmi->audio.rate = HDMI_AUDIO_DEFAULT_RATE;