X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=arch%2Farm%2Fmach-mx3%2Fmx31moboard-marxbot.c;h=f449a97ae1a22293e3e5bc61881aa551a2b211eb;hb=2a85927c79634e89b9cd683dd2bae65966d9b216;hp=18069cb7d068c2a2a6cc1ea5300fbbab71abfaa1;hpb=3561d43fd289f590fdae672e5eb831b8d5cf0bf6;p=pandora-kernel.git diff --git a/arch/arm/mach-mx3/mx31moboard-marxbot.c b/arch/arm/mach-mx3/mx31moboard-marxbot.c index 18069cb7d068..f449a97ae1a2 100644 --- a/arch/arm/mach-mx3/mx31moboard-marxbot.c +++ b/arch/arm/mach-mx3/mx31moboard-marxbot.c @@ -21,7 +21,6 @@ #include #include #include -#include #include @@ -29,12 +28,11 @@ #include #include #include -#include -#include #include #include +#include "devices-imx31.h" #include "devices.h" static unsigned int marxbot_pins[] = { @@ -116,7 +114,7 @@ static void marxbot_sdhc2_exit(struct device *dev, void *data) gpio_free(SDHC2_CD); } -static struct imxmmc_platform_data sdhc2_pdata = { +static const struct imxmmc_platform_data sdhc2_pdata __initconst = { .get_ro = marxbot_sdhc2_get_ro, .init = marxbot_sdhc2_init, .exit = marxbot_sdhc2_exit, @@ -302,7 +300,7 @@ static int marxbot_isp1105_set_vbus(struct otg_transceiver *otg, bool on) return 0; } -static struct mxc_usbh_platform_data usbh1_pdata = { +static struct mxc_usbh_platform_data usbh1_pdata __initdata = { .init = marxbot_usbh1_hw_init, .portsc = MXC_EHCI_MODE_UTMI | MXC_EHCI_SERIAL, .flags = MXC_EHCI_POWER_PINS_ENABLED | MXC_EHCI_INTERFACE_SINGLE_UNI, @@ -311,6 +309,7 @@ static struct mxc_usbh_platform_data usbh1_pdata = { static int __init marxbot_usbh1_init(void) { struct otg_transceiver *otg; + struct platform_device *pdev; otg = kzalloc(sizeof(*otg), GFP_KERNEL); if (!otg) @@ -322,10 +321,14 @@ static int __init marxbot_usbh1_init(void) usbh1_pdata.otg = otg; - return mxc_register_device(&mxc_usbh1, &usbh1_pdata); + pdev = imx31_add_mxc_ehci_hs(1, &usbh1_pdata); + if (IS_ERR(pdev)) + return PTR_ERR(pdev); + + return 0; } -static struct fsl_usb2_platform_data usb_pdata = { +static const struct fsl_usb2_platform_data usb_pdata __initconst = { .operating_mode = FSL_USB2_DR_DEVICE, .phy_mode = FSL_USB2_PHY_ULPI, }; @@ -344,7 +347,7 @@ void __init mx31moboard_marxbot_init(void) dspics_resets_init(); - mxc_register_device(&mxcsdhc_device1, &sdhc2_pdata); + imx31_add_mxc_mmc(1, &sdhc2_pdata); spi_register_board_info(marxbot_spi_board_info, ARRAY_SIZE(marxbot_spi_board_info)); @@ -357,7 +360,7 @@ void __init mx31moboard_marxbot_init(void) gpio_direction_input(IOMUX_TO_GPIO(MX31_PIN_LCS0)); gpio_export(IOMUX_TO_GPIO(MX31_PIN_LCS0), false); - mxc_register_device(&mxc_otg_udc_device, &usb_pdata); + imx31_add_fsl_usb2_udc(&usb_pdata); marxbot_usbh1_init(); }