omap3: beaglexm: fix EHCI power up GPIO dir
[deliverable/linux.git] / arch / arm / mach-omap2 / board-omap3beagle.c
index 14f42240ae792bf01fcd289d60d441d9d55eb328..af1166bd1c868e462e87d97c99f0f134781b679a 100644 (file)
@@ -297,9 +297,15 @@ static int beagle_twl_gpio_setup(struct device *dev,
        gpio_request(gpio + 1, "EHCI_nOC");
        gpio_direction_input(gpio + 1);
 
-       /* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, active low) */
+       /*
+        * TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, XM active
+        * high / others active low)
+        */
        gpio_request(gpio + TWL4030_GPIO_MAX, "nEN_USB_PWR");
-       gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
+       if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
+               gpio_direction_output(gpio + TWL4030_GPIO_MAX, 1);
+       else
+               gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
 
        /* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */
        gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1;
@@ -484,13 +490,13 @@ static struct platform_device keys_gpio = {
 
 static void __init omap3_beagle_init_irq(void)
 {
-       omap2_init_common_hw(mt46h32m32lf6_sdrc_params,
-                            mt46h32m32lf6_sdrc_params);
+       omap2_init_common_infrastructure();
+       omap2_init_common_devices(mt46h32m32lf6_sdrc_params,
+                                 mt46h32m32lf6_sdrc_params);
        omap_init_irq();
 #ifdef CONFIG_OMAP_32K_TIMER
        omap2_gp_clockevent_set_gptimer(12);
 #endif
-       omap_gpio_init();
 }
 
 static struct platform_device *omap3_beagle_devices[] __initdata = {
@@ -548,8 +554,6 @@ static const struct ehci_hcd_omap_platform_data ehci_pdata __initconst = {
 static struct omap_board_mux board_mux[] __initdata = {
        { .reg_offset = OMAP_MUX_TERMINATOR },
 };
-#else
-#define board_mux      NULL
 #endif
 
 static struct omap_musb_board_data musb_board_data = {
This page took 0.027841 seconds and 5 git commands to generate.