Skip to contentSkip to conversation

SMDK5250: Enable VBus for USB 2.0 controller

PATCH New Vivek Gautam 2 participants 2 messages Jan 8, 2013

lore
Share & tools
lore
#0 lore raw

PATCH v4 1/1 SMDK5250: Enable VBus for USB 2.0 controller

This patch enables Vbus required for USB 2.0 controller.

---

Changes from v3:
- Rebased on top of u-boot-samsung/master.

Changes from v2:
- Rebased on top of u-boot-usb/next
- Enclosed the function definition for board_usb_vbus_init() inside "CONFIG_USB_EHCI_EXYNOS"

Changes from v1:
- Using the old school method of setting up gpio instead of using the pinmux method, since the required gpio line here is board specific.

 board/samsung/smdk5250/smdk5250.c |   19 +++++++++++++++++++
 1 files changed, 19 insertions(+), 0 deletions(-)
board/samsung/smdk5250/smdk5250.c +19 -0
index 73c3ec0..d80f75d 100644
@@ -35,12 +35,31 @@
 
 DECLARE_GLOBAL_DATA_PTR;
 
+#ifdef CONFIG_USB_EHCI_EXYNOS
+int board_usb_vbus_init(void)
+{
+	struct exynos5_gpio_part1 *gpio1 = (struct exynos5_gpio_part1 *)
+						samsung_get_base_gpio_part1();
+
+	/* Enable VBUS power switch */
+	s5p_gpio_direction_output(&gpio1->x2, 6, 1);
+
+	/* VBUS turn ON time */
+	mdelay(3);
+
+	return 0;
+}
+#endif
+
 int board_init(void)
 {
 	gd->bd->bi_boot_params = (PHYS_SDRAM_1 + 0x100UL);
 #ifdef CONFIG_EXYNOS_SPI
 	spi_init();
 #endif
+#ifdef CONFIG_USB_EHCI_EXYNOS
+	board_usb_vbus_init();
+#endif
 	return 0;
 }
 
Signature · 1 line
1.7.6.5
#1 lore raw

PATCH v4 1/1 SMDK5250: Enable VBus for USB 2.0 controller

Quoted 14 lines · Vivek Gautam

This patch enables Vbus required for USB 2.0 controller.

---

Changes from v3:
- Rebased on top of u-boot-samsung/master.

Changes from v2:
- Rebased on top of u-boot-usb/next
- Enclosed the function definition for board_usb_vbus_init() inside "CONFIG_USB_EHCI_EXYNOS"

Quoted 8 lines

Changes from v1:
- Using the old school method of setting up gpio instead of using the pinmux method, since the required gpio line here is board specific.

 board/samsung/smdk5250/smdk5250.c |   19 +++++++++++++++++++
 1 files changed, 19 insertions(+), 0 deletions(-)

applied to u-boot-samsung.

Thanks,
Minkyu Kang.