mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-09 20:32:04 +09:00
HDMI:rk3128/rk3036:
1. For MID, remove interlace mode support and set default mode to be enabled. 2. If HDMI is disabled, disable hotplug irq. Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
This commit is contained in:
@@ -198,8 +198,7 @@ static irqreturn_t rockchip_hdmiv1_irq_func(int irq, void *dev_id)
|
||||
{
|
||||
struct hdmi *hdmi_drv = hdmi_dev->hdmi;
|
||||
|
||||
if ((hdmi_drv->sleep == 0) && (hdmi_drv->enable == 1))
|
||||
rockchip_hdmiv1_irq(hdmi_drv);
|
||||
rockchip_hdmiv1_irq(hdmi_drv);
|
||||
|
||||
return IRQ_HANDLED;
|
||||
}
|
||||
@@ -322,8 +321,9 @@ static int rockchip_hdmiv1_probe(struct platform_device *pdev)
|
||||
rockchip_hdmiv1_dev_init_ops(&rockchip_hdmiv1_ops);
|
||||
rockchip_hdmiv1_property.name = (char *)pdev->name;
|
||||
rockchip_hdmiv1_property.priv = hdmi_dev;
|
||||
rockchip_hdmiv1_property.feature |= SUPPORT_1080I |
|
||||
SUPPORT_480I_576I;
|
||||
if (rk_fb_get_display_policy() == DISPLAY_POLICY_BOX)
|
||||
rockchip_hdmiv1_property.feature |= SUPPORT_1080I |
|
||||
SUPPORT_480I_576I;
|
||||
hdmi_dev->hdmi = rockchip_hdmi_register(&rockchip_hdmiv1_property,
|
||||
&rockchip_hdmiv1_ops);
|
||||
if (hdmi_dev->hdmi == NULL) {
|
||||
@@ -336,13 +336,12 @@ static int rockchip_hdmiv1_probe(struct platform_device *pdev)
|
||||
fb_register_client(&rockchip_hdmiv1_fb_notifier);
|
||||
rockchip_hdmiv1_initial(hdmi_dev->hdmi);
|
||||
|
||||
if (rk_fb_get_display_policy() == DISPLAY_POLICY_BOX) {
|
||||
rk_display_device_enable(hdmi_dev->hdmi->ddev);
|
||||
delay_work = hdmi_submit_work(hdmi_dev->hdmi,
|
||||
HDMI_HPD_CHANGE, 0, NULL);
|
||||
if (delay_work)
|
||||
flush_delayed_work(delay_work);
|
||||
}
|
||||
rk_display_device_enable(hdmi_dev->hdmi->ddev);
|
||||
delay_work = hdmi_submit_work(hdmi_dev->hdmi,
|
||||
HDMI_HPD_CHANGE, 0, NULL);
|
||||
if (delay_work)
|
||||
flush_delayed_work(delay_work);
|
||||
|
||||
#if defined(CONFIG_DEBUG_FS)
|
||||
hdmi_dev->debugfs_dir = debugfs_create_dir("rockchip_hdmiv1", NULL);
|
||||
if (IS_ERR(hdmi_dev->debugfs_dir)) {
|
||||
|
||||
@@ -866,8 +866,11 @@ static int rockchip_hdmiv1_enable(struct hdmi *hdmi_drv)
|
||||
{
|
||||
struct hdmi_dev *hdmi_dev = hdmi_drv->property->priv;
|
||||
|
||||
if (!hdmi_dev->enable)
|
||||
if (!hdmi_dev->enable) {
|
||||
hdmi_dev->enable = 1;
|
||||
hdmi_msk_reg(hdmi_dev, HDMI_STATUS,
|
||||
m_MASK_INT_HOTPLUG, v_MASK_INT_HOTPLUG(1));
|
||||
}
|
||||
hdmi_submit_work(hdmi_drv, HDMI_HPD_CHANGE, 10, NULL);
|
||||
return 0;
|
||||
}
|
||||
@@ -876,9 +879,11 @@ static int rockchip_hdmiv1_disable(struct hdmi *hdmi_drv)
|
||||
{
|
||||
struct hdmi_dev *hdmi_dev = hdmi_drv->property->priv;
|
||||
|
||||
if (hdmi_dev->enable)
|
||||
if (hdmi_dev->enable) {
|
||||
hdmi_dev->enable = 0;
|
||||
|
||||
hdmi_msk_reg(hdmi_dev, HDMI_STATUS,
|
||||
m_MASK_INT_HOTPLUG, v_MASK_INT_HOTPLUG(0));
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -948,6 +953,8 @@ int rockchip_hdmiv1_initial(struct hdmi *hdmi_drv)
|
||||
if (!hdmi_drv->uboot) {
|
||||
rockchip_hdmiv1_reset_pclk();
|
||||
rockchip_hdmiv1_reset(hdmi_drv);
|
||||
hdmi_msk_reg(hdmi_dev, HDMI_STATUS,
|
||||
m_MASK_INT_HOTPLUG, v_MASK_INT_HOTPLUG(0));
|
||||
} else if (hdmi_drv->ops->getstatus(hdmi_drv) == HDMI_HPD_REMOVED) {
|
||||
rockchip_hdmiv1_removed(hdmi_drv);
|
||||
hdmi_drv->lcdc->uboot_logo = 0;
|
||||
|
||||
Reference in New Issue
Block a user