aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRicardo Salveti de Araujo <ricardo.salveti@canonical.com>2011-01-28 02:10:37 -0200
committerRicardo Salveti de Araujo <ricardo.salveti@linaro.org>2011-05-24 04:21:58 -0300
commit19fe60d2d723c403620caaf297956a3303c5d155 (patch)
tree3f2f33fe90b291a249ae5647352765a01a78485c
parent40eb35bb55b86951ce6a93a6937ceff2e0fc45f9 (diff)
downloadlinux-linaro-android-19fe60d2d723c403620caaf297956a3303c5d155.tar.gz
omap3: beaglexm: fix DVI initialization
Function beagle_twl_gpio_setup is called after beagle_display_init, what makes lets reset_gpio with an invalid value at the time it request the gpio. As a side effect the DVI reset GPIO is not properly set. Also removing old code that power down DVI in a hardcoded way, as it's not necessary anymore. Tested with Beagle-xM and C4. Signed-off-by: Ricardo Salveti de Araujo <ricardo.salveti@canonical.com>
-rw-r--r--arch/arm/mach-omap2/board-omap3beagle.c17
1 files changed, 6 insertions, 11 deletions
diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
index 34b0cb4d189..831e98d2ebb 100644
--- a/arch/arm/mach-omap2/board-omap3beagle.c
+++ b/arch/arm/mach-omap2/board-omap3beagle.c
@@ -244,6 +244,12 @@ static void __init beagle_display_init(void)
{
int r;
+ /* DVI reset GPIO is different between beagle revisions */
+ if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
+ beagle_dvi_device.reset_gpio = 129;
+ else
+ beagle_dvi_device.reset_gpio = 170;
+
r = gpio_request(beagle_dvi_device.reset_gpio, "DVI reset");
if (r < 0) {
printk(KERN_ERR "Unable to get DVI reset GPIO\n");
@@ -320,12 +326,6 @@ static int beagle_twl_gpio_setup(struct device *dev,
else
gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
- /* DVI reset GPIO is different between beagle revisions */
- if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
- beagle_dvi_device.reset_gpio = 129;
- else
- beagle_dvi_device.reset_gpio = 170;
-
/* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */
gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1;
@@ -665,11 +665,6 @@ static void __init omap3_beagle_init(void)
omap_display_init(&beagle_dss_data);
omap_serial_init();
- omap_mux_init_gpio(170, OMAP_PIN_INPUT);
- gpio_request(170, "DVI_nPD");
- /* REVISIT leave DVI powered down until it's needed ... */
- gpio_direction_output(170, true);
-
usb_musb_init(&musb_board_data);
usbhs_init(&usbhs_bdata);
omap3beagle_flash_init();