aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorK, Mythri P <mythripk@ti.com>2011-05-03 12:18:16 +0800
committerRicardo Salveti de Araujo <ricardo.salveti@canonical.com>2011-05-16 22:42:11 -0300
commit9b97b02e3d7fbd45ccf13cf5577f318644dc91d3 (patch)
tree5f5ea675b4820b352ae5f624b81fc83003cee166
parentd00cf79c8a4691c0406a2db57643db856b861fc0 (diff)
downloadlinux-linaro-android-9b97b02e3d7fbd45ccf13cf5577f318644dc91d3.tar.gz
OMAP4 : HDMI : Add HDMI structure in the board file for OMAP4 PANDA
Adding board file structure for display which adds the display structure with HDMI as the default driver when the display init is called. HDMI GPIO configurations are also done in this file. Signed-off-by: Mythri P K <mythripk@ti.com> Signed-off-by: Sebastien Jan <s-jan@ti.com>
-rw-r--r--arch/arm/mach-omap2/board-omap4panda.c44
1 files changed, 44 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/board-omap4panda.c b/arch/arm/mach-omap2/board-omap4panda.c
index 952784d852b..375a5ec9716 100644
--- a/arch/arm/mach-omap2/board-omap4panda.c
+++ b/arch/arm/mach-omap2/board-omap4panda.c
@@ -98,6 +98,50 @@ static struct platform_device *panda_devices[] __initdata = {
&wl1271_device,
};
+/* Display DVI */
+#define PANDA_DVI_TFP410_POWER_DOWN_GPIO 0
+
+static int panda_enable_dvi(struct omap_dss_device *dssdev)
+{
+ gpio_set_value(dssdev->reset_gpio, 1);
+ return 0;
+}
+
+static void panda_disable_dvi(struct omap_dss_device *dssdev)
+{
+ gpio_set_value(dssdev->reset_gpio, 0);
+}
+
+/* Using generic display panel */
+static struct panel_generic_dpi_data dvi_panel = {
+ .name = "generic",
+ .platform_enable = panda_enable_dvi,
+ .platform_disable = panda_disable_dvi,
+};
+
+struct omap_dss_device panda_dvi_device = {
+ .type = OMAP_DISPLAY_TYPE_DPI,
+ .name = "dvi",
+ .driver_name = "generic_dpi_panel",
+ .data = &dvi_panel,
+ .phy.dpi.data_lines = 24,
+ .reset_gpio = PANDA_DVI_TFP410_POWER_DOWN_GPIO,
+ .channel = OMAP_DSS_CHANNEL_LCD2,
+};
+
+int __init panda_dvi_init(void)
+{
+ int r;
+
+ /* Requesting TFP410 DVI GPIO and disabling it, at bootup */
+ r = gpio_request_one(panda_dvi_device.reset_gpio,
+ GPIOF_OUT_INIT_LOW, "DVI PD");
+ if (r)
+ pr_err("Failed to get DVI powerdown GPIO\n");
+
+ return r;
+}
+
static void __init omap4_panda_init_early(void)
{
omap2_init_common_infrastructure();