ARM: mx3: dynamically allocate mxc-ehci devices
[pandora-kernel.git] / arch / arm / mach-mx3 / mach-pcm037.c
index 20f7f94..2d29743 100644 (file)
@@ -44,7 +44,6 @@
 #include <mach/ipu.h>
 #include <mach/mx3_camera.h>
 #include <mach/mx3fb.h>
-#include <mach/mxc_ehci.h>
 #include <mach/ulpi.h>
 
 #include "devices-imx31.h"
@@ -538,12 +537,12 @@ static struct platform_device pcm970_sja1000 = {
 };
 
 #if defined(CONFIG_USB_ULPI)
-static struct mxc_usbh_platform_data otg_pdata = {
+static struct mxc_usbh_platform_data otg_pdata __initdata = {
        .portsc = MXC_EHCI_MODE_ULPI,
        .flags  = MXC_EHCI_INTERFACE_DIFF_UNI,
 };
 
-static struct mxc_usbh_platform_data usbh2_pdata = {
+static struct mxc_usbh_platform_data usbh2_pdata __initdata = {
        .portsc = MXC_EHCI_MODE_ULPI,
        .flags  = MXC_EHCI_INTERFACE_DIFF_UNI,
 };
@@ -654,13 +653,13 @@ static void __init mxc_board_init(void)
                otg_pdata.otg = otg_ulpi_create(&mxc_ulpi_access_ops,
                                ULPI_OTG_DRVVBUS | ULPI_OTG_DRVVBUS_EXT);
 
-               mxc_register_device(&mxc_otg_host, &otg_pdata);
+               imx31_add_mxc_ehci_otg(&otg_pdata);
        }
 
        usbh2_pdata.otg = otg_ulpi_create(&mxc_ulpi_access_ops,
                                ULPI_OTG_DRVVBUS | ULPI_OTG_DRVVBUS_EXT);
 
-       mxc_register_device(&mxc_usbh2, &usbh2_pdata);
+       imx31_add_mxc_ehci_hs(2, &usbh2_pdata);
 #endif
        if (!otg_mode_host)
                imx31_add_fsl_usb2_udc(&otg_device_pdata);