rk30 hdmi:

1. add function hdmi_get_hotplug(void) to poll hdmi hotplug status for other modules.
	2. add macro HDMI_AUTO_CONFIGURE in rk30_hdmi.h to enable/disable auto confiure output mode according EDID.
This commit is contained in:
Zheng Yang
2012-04-17 11:48:24 +08:00
parent 322bef5abe
commit 4afa48a5b7
4 changed files with 21 additions and 1 deletions

View File

@@ -21,10 +21,17 @@ enum {
HDMI_SOURCE_LCDC1 = 1
};
/* default HDMI video source */
#define HDMI_SOURCE_DEFAULT HDMI_SOURCE_LCDC1
/* If HDMI_ENABLE, system will auto configure output mode according to EDID
* If HDMI_DISABLE, system will output mode according to macro HDMI_VIDEO_DEFAULT_MODE
*/
#define HDMI_AUTO_CONFIGURE HDMI_ENABLE
/* default HDMI output video mode */
#define HDMI_VIDEO_DEFAULT_MODE HDMI_1280x720p_60Hz//HDMI_1920x1080p_60Hz
/* default HDMI output audio mode */
#define HDMI_AUDIO_DEFAULT_CHANNEL 2
#define HDMI_AUDIO_DEFAULT_RATE HDMI_AUDIO_FS_44100
#define HDMI_AUDIO_DEFAULT_WORD_LENGTH HDMI_AUDIO_WORD_LENGTH_16bit

View File

@@ -513,3 +513,14 @@ int hdmi_switch_fb(struct hdmi *hdmi, int vic)
}
return rc;
}
/**
* hdmi_get_status: get hdmi hotplug status
*
* NOTES:
*
*/
int hdmi_get_hotplug(void)
{
return hdmi->hotplug;
}

View File

@@ -48,7 +48,7 @@ int hdmi_sys_init(void)
hdmi->hotplug = HDMI_HPD_REMOVED;
hdmi->state = HDMI_SLEEP;
hdmi->enable = HDMI_ENABLE;
hdmi->autoconfig = HDMI_ENABLE;
hdmi->autoconfig = HDMI_AUTO_CONFIGURE;
hdmi->vic = HDMI_VIDEO_DEFAULT_MODE;
hdmi->audio.channel = HDMI_AUDIO_DEFAULT_CHANNEL;

View File

@@ -195,4 +195,6 @@ extern const struct fb_videomode hdmi_mode[];
#define hdmi_dbg(dev, format, arg...)
#endif
extern int hdmi_get_hotplug(void);
#endif