Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 68fc3e15 authored by Koen Kooi's avatar Koen Kooi Committed by Tony Lindgren
Browse files

omap3: beaglexm: fix EHCI power up GPIO dir



EHCI enable power pin is inverted (active high) in comparison
to vanilla beagle which is active low. Handle this case conditionally.

Without this fix, Beagle XM 4 port EHCI will not function and no
networking will be available

[nm@ti.com: split up, added descriptive changelogs]
Signed-off-by: default avatarNishanth Menon <nm@ti.com>
Signed-off-by: default avatarKoen Kooi <koen@beagleboard.org>
Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
parent 18cbc7d9
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -297,8 +297,14 @@ 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");
	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) */