diff mbox

[7/7] Updating the Leopard board USB config for DM355 Platform.

Message ID 1254937992-2291-8-git-send-email-swami.iyer@ti.com (mailing list archive)
State Superseded
Headers show

Commit Message

Subbrathnam, Swaminathan Oct. 7, 2009, 5:53 p.m. UTC
None
diff mbox

Patch

diff --git a/arch/arm/mach-davinci/board-dm355-leopard.c b/arch/arm/mach-davinci/board-dm355-leopard.c
index 84ad5d1..08b3fc6 100644
--- a/arch/arm/mach-davinci/board-dm355-leopard.c
+++ b/arch/arm/mach-davinci/board-dm355-leopard.c
@@ -36,6 +36,7 @@ 
 #include <mach/serial.h>
 #include <mach/nand.h>
 #include <mach/mmc.h>
+#include <mach/usb_davinci.h>
 
 #define DAVINCI_ASYNC_EMIF_CONTROL_BASE		0x01e10000
 #define DAVINCI_ASYNC_EMIF_DATA_CE0_BASE	0x02000000
@@ -243,6 +244,21 @@  static struct spi_board_info dm355_leopard_spi_info[] __initconst = {
 	},
 };
 
+static struct musb_hdrc_platform_data usb_evm_data[] = {
+	{
+#if defined(CONFIG_USB_MUSB_OTG)
+		.mode = MUSB_OTG,
+#elif defined(CONFIG_USB_MUSB_PERIPHERAL)
+		.mode =  MUSB_PERIPHERAL,
+#elif defined(CONFIG_USB_MUSB_HOST)
+		.mode = MUSB_HOST,
+#endif
+		.power = 255,
+		.potpgt = 8,
+		.set_vbus = NULL, /* VBUS is controller by USB IP */
+	}
+};
+
 static __init void dm355_leopard_init(void)
 {
 	struct clk *aemif;
@@ -270,7 +286,7 @@  static __init void dm355_leopard_init(void)
 	gpio_request(2, "usb_id_toggle");
 	gpio_direction_output(2, USB_ID_VALUE);
 	/* irlml6401 switches over 1A in under 8 msec */
-	setup_usb(500, 8);
+	dm355_usb_configure(usb_evm_data, ARRAY_SIZE(usb_evm_data));
 
 	davinci_setup_mmc(0, &dm355leopard_mmc_config);
 	davinci_setup_mmc(1, &dm355leopard_mmc_config);