aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-mx3/mx31moboard-devboard.c
diff options
context:
space:
mode:
authorPhilippe Rétornaz <philippe.retornaz@epfl.ch>2010-05-11 10:57:50 -0400
committerSascha Hauer <s.hauer@pengutronix.de>2010-05-17 04:05:50 -0400
commit66c202ad9a58905e0e6a0fa3976020a7ab0fa6df (patch)
treec8559ce3f8e34002228844a21172f499935f291f /arch/arm/mach-mx3/mx31moboard-devboard.c
parent25783602050600b294086d6a0be9a0c2cfe8a3e3 (diff)
mx31moboard: Move usb OTG device registration
In preparation for a new robot which needs the OTG port as host. This moves the OTG device registration into board initialisation. Signed-off-by: Philippe Rétornaz <philippe.retornaz@epfl.ch> Acked-by: Valentin Longchamp <valentin.longchamp@epfl.ch> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/arm/mach-mx3/mx31moboard-devboard.c')
-rw-r--r--arch/arm/mach-mx3/mx31moboard-devboard.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/arm/mach-mx3/mx31moboard-devboard.c b/arch/arm/mach-mx3/mx31moboard-devboard.c
index 11b906ce7eae..582299cb2c08 100644
--- a/arch/arm/mach-mx3/mx31moboard-devboard.c
+++ b/arch/arm/mach-mx3/mx31moboard-devboard.c
@@ -22,6 +22,7 @@
22#include <linux/platform_device.h> 22#include <linux/platform_device.h>
23#include <linux/slab.h> 23#include <linux/slab.h>
24#include <linux/types.h> 24#include <linux/types.h>
25#include <linux/fsl_devices.h>
25 26
26#include <linux/usb/otg.h> 27#include <linux/usb/otg.h>
27 28
@@ -213,6 +214,12 @@ static int __init devboard_usbh1_init(void)
213 return mxc_register_device(&mxc_usbh1, &usbh1_pdata); 214 return mxc_register_device(&mxc_usbh1, &usbh1_pdata);
214} 215}
215 216
217
218static struct fsl_usb2_platform_data usb_pdata = {
219 .operating_mode = FSL_USB2_DR_DEVICE,
220 .phy_mode = FSL_USB2_PHY_ULPI,
221};
222
216/* 223/*
217 * system init for baseboard usage. Will be called by mx31moboard init. 224 * system init for baseboard usage. Will be called by mx31moboard init.
218 */ 225 */
@@ -229,5 +236,7 @@ void __init mx31moboard_devboard_init(void)
229 236
230 devboard_init_sel_gpios(); 237 devboard_init_sel_gpios();
231 238
239 mxc_register_device(&mxc_otg_udc_device, &usb_pdata);
240
232 devboard_usbh1_init(); 241 devboard_usbh1_init();
233} 242}