summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-mx3/mach-mx35_3ds.c
diff options
context:
space:
mode:
authorSascha Hauer2011-01-03 11:30:28 +0100
committerSascha Hauer2011-02-11 08:40:45 +0100
commit4bd597b633ae630e09d58957bd99870eac35fcb4 (patch)
tree39b829bee667531ac41ea48d7f392ecb9258f956 /arch/arm/mach-mx3/mach-mx35_3ds.c
parentARM i.MX ehci: factor out soc specific functions (diff)
downloadkernel-qcow2-linux-4bd597b633ae630e09d58957bd99870eac35fcb4.tar.gz
kernel-qcow2-linux-4bd597b633ae630e09d58957bd99870eac35fcb4.tar.xz
kernel-qcow2-linux-4bd597b633ae630e09d58957bd99870eac35fcb4.zip
ARM i.MX ehci: do ehci init in board specific functions
The mxc-ehci driver calls SoC specific phy initialization right after calling board specific initialization. To offer greater flexibility for boards to setup the phy and to get rid of some unnecessary flags in platform data this patch lets the boards call the SoC specific phy initialization and remove it from the driver. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/arm/mach-mx3/mach-mx35_3ds.c')
-rw-r--r--arch/arm/mach-mx3/mach-mx35_3ds.c16
1 files changed, 13 insertions, 3 deletions
diff --git a/arch/arm/mach-mx3/mach-mx35_3ds.c b/arch/arm/mach-mx3/mach-mx35_3ds.c
index c5115dc5c0c5..dac1896a5b21 100644
--- a/arch/arm/mach-mx3/mach-mx35_3ds.c
+++ b/arch/arm/mach-mx3/mach-mx35_3ds.c
@@ -120,6 +120,11 @@ static iomux_v3_cfg_t mx35pdk_pads[] = {
MX35_PAD_SD1_DATA3__ESDHC1_DAT3,
};
+static int mx35_3ds_otg_init(struct platform_device *pdev)
+{
+ return mx35_initialize_usb_hw(pdev->id, MXC_EHCI_INTERNAL_PHY);
+}
+
/* OTG config */
static const struct fsl_usb2_platform_data usb_otg_pdata __initconst = {
.operating_mode = FSL_USB2_DR_DEVICE,
@@ -127,15 +132,20 @@ static const struct fsl_usb2_platform_data usb_otg_pdata __initconst = {
};
static struct mxc_usbh_platform_data otg_pdata __initdata = {
+ .init = mx35_3ds_otg_init,
.portsc = MXC_EHCI_MODE_UTMI,
- .flags = MXC_EHCI_INTERNAL_PHY,
};
+static int mx35_3ds_usbh_init(struct platform_device *pdev)
+{
+ return mx35_initialize_usb_hw(pdev->id, MXC_EHCI_INTERFACE_SINGLE_UNI |
+ MXC_EHCI_INTERNAL_PHY);
+}
+
/* USB HOST config */
static const struct mxc_usbh_platform_data usb_host_pdata __initconst = {
+ .init = mx35_3ds_usbh_init,
.portsc = MXC_EHCI_MODE_SERIAL,
- .flags = MXC_EHCI_INTERFACE_SINGLE_UNI |
- MXC_EHCI_INTERNAL_PHY,
};
static int otg_mode_host;