aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-imx
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-imx')
-rw-r--r--arch/arm/mach-imx/Kconfig2
-rw-r--r--arch/arm/mach-imx/devices-imx27.h4
-rw-r--r--arch/arm/mach-imx/devices.c28
-rw-r--r--arch/arm/mach-imx/devices.h1
-rw-r--r--arch/arm/mach-imx/mach-cpuimx27.c5
-rw-r--r--arch/arm/mach-imx/mach-pca100.c5
6 files changed, 10 insertions, 35 deletions
diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig
index 025e96925561..e50a164d08f7 100644
--- a/arch/arm/mach-imx/Kconfig
+++ b/arch/arm/mach-imx/Kconfig
@@ -128,6 +128,7 @@ endchoice
128 128
129config MACH_CPUIMX27 129config MACH_CPUIMX27
130 bool "Eukrea CPUIMX27 module" 130 bool "Eukrea CPUIMX27 module"
131 select IMX_HAVE_PLATFORM_FSL_USB2_UDC
131 select IMX_HAVE_PLATFORM_IMX2_WDT 132 select IMX_HAVE_PLATFORM_IMX2_WDT
132 select IMX_HAVE_PLATFORM_IMX_I2C 133 select IMX_HAVE_PLATFORM_IMX_I2C
133 select IMX_HAVE_PLATFORM_IMX_UART 134 select IMX_HAVE_PLATFORM_IMX_UART
@@ -200,6 +201,7 @@ config MACH_IMX27LITE
200 201
201config MACH_PCA100 202config MACH_PCA100
202 bool "Phytec phyCARD-s (pca100)" 203 bool "Phytec phyCARD-s (pca100)"
204 select IMX_HAVE_PLATFORM_FSL_USB2_UDC
203 select IMX_HAVE_PLATFORM_IMX2_WDT 205 select IMX_HAVE_PLATFORM_IMX2_WDT
204 select IMX_HAVE_PLATFORM_IMX_FB 206 select IMX_HAVE_PLATFORM_IMX_FB
205 select IMX_HAVE_PLATFORM_IMX_I2C 207 select IMX_HAVE_PLATFORM_IMX_I2C
diff --git a/arch/arm/mach-imx/devices-imx27.h b/arch/arm/mach-imx/devices-imx27.h
index 51b91553c590..51bb42d8536e 100644
--- a/arch/arm/mach-imx/devices-imx27.h
+++ b/arch/arm/mach-imx/devices-imx27.h
@@ -13,6 +13,10 @@ extern const struct imx_fec_data imx27_fec_data __initconst;
13#define imx27_add_fec(pdata) \ 13#define imx27_add_fec(pdata) \
14 imx_add_fec(&imx27_fec_data, pdata) 14 imx_add_fec(&imx27_fec_data, pdata)
15 15
16extern const struct imx_fsl_usb2_udc_data imx27_fsl_usb2_udc_data __initconst;
17#define imx27_add_fsl_usb2_udc(pdata) \
18 imx_add_fsl_usb2_udc(&imx27_fsl_usb2_udc_data, pdata)
19
16extern const struct imx_imx2_wdt_data imx27_imx2_wdt_data __initconst; 20extern const struct imx_imx2_wdt_data imx27_imx2_wdt_data __initconst;
17#define imx27_add_imx2_wdt(pdata) \ 21#define imx27_add_imx2_wdt(pdata) \
18 imx_add_imx2_wdt(&imx27_imx2_wdt_data) 22 imx_add_imx2_wdt(&imx27_imx2_wdt_data)
diff --git a/arch/arm/mach-imx/devices.c b/arch/arm/mach-imx/devices.c
index 2a6d70720e99..d026cfbe6130 100644
--- a/arch/arm/mach-imx/devices.c
+++ b/arch/arm/mach-imx/devices.c
@@ -76,34 +76,6 @@ int __init imx1_register_gpios(void)
76} 76}
77#endif 77#endif
78 78
79#ifdef CONFIG_MACH_MX27
80static struct resource otg_resources[] = {
81 {
82 .start = MX27_USB_OTG_BASE_ADDR,
83 .end = MX27_USB_OTG_BASE_ADDR + 0x1ff,
84 .flags = IORESOURCE_MEM,
85 }, {
86 .start = MX27_INT_USB_OTG,
87 .end = MX27_INT_USB_OTG,
88 .flags = IORESOURCE_IRQ,
89 },
90};
91
92static u64 otg_dmamask = DMA_BIT_MASK(32);
93
94/* OTG gadget device */
95struct platform_device mxc_otg_udc_device = {
96 .name = "fsl-usb2-udc",
97 .id = -1,
98 .dev = {
99 .dma_mask = &otg_dmamask,
100 .coherent_dma_mask = DMA_BIT_MASK(32),
101 },
102 .resource = otg_resources,
103 .num_resources = ARRAY_SIZE(otg_resources),
104};
105#endif
106
107#if defined(CONFIG_MACH_MX21) || defined(CONFIG_MACH_MX27) 79#if defined(CONFIG_MACH_MX21) || defined(CONFIG_MACH_MX27)
108/* GPIO port description */ 80/* GPIO port description */
109#define DEFINE_MXC_GPIO_PORT_IRQ(SOC, n, _irq) \ 81#define DEFINE_MXC_GPIO_PORT_IRQ(SOC, n, _irq) \
diff --git a/arch/arm/mach-imx/devices.h b/arch/arm/mach-imx/devices.h
index 7a00bba3688e..a788566c1938 100644
--- a/arch/arm/mach-imx/devices.h
+++ b/arch/arm/mach-imx/devices.h
@@ -1,5 +1,4 @@
1#if defined(CONFIG_MACH_MX21) || defined(CONFIG_MACH_MX27) 1#if defined(CONFIG_MACH_MX21) || defined(CONFIG_MACH_MX27)
2extern struct platform_device mxc_otg_udc_device;
3extern struct platform_device mx21_usbhc_device; 2extern struct platform_device mx21_usbhc_device;
4extern struct platform_device imx_kpp_device; 3extern struct platform_device imx_kpp_device;
5#endif 4#endif
diff --git a/arch/arm/mach-imx/mach-cpuimx27.c b/arch/arm/mach-imx/mach-cpuimx27.c
index c70b0382363e..9ae5bed90ed8 100644
--- a/arch/arm/mach-imx/mach-cpuimx27.c
+++ b/arch/arm/mach-imx/mach-cpuimx27.c
@@ -28,7 +28,6 @@
28#include <linux/serial_8250.h> 28#include <linux/serial_8250.h>
29#include <linux/usb/otg.h> 29#include <linux/usb/otg.h>
30#include <linux/usb/ulpi.h> 30#include <linux/usb/ulpi.h>
31#include <linux/fsl_devices.h>
32 31
33#include <asm/mach-types.h> 32#include <asm/mach-types.h>
34#include <asm/mach/arch.h> 33#include <asm/mach/arch.h>
@@ -223,7 +222,7 @@ static struct mxc_usbh_platform_data usbh2_pdata __initdata = {
223}; 222};
224#endif 223#endif
225 224
226static struct fsl_usb2_platform_data otg_device_pdata = { 225static const struct fsl_usb2_platform_data otg_device_pdata __initconst = {
227 .operating_mode = FSL_USB2_DR_DEVICE, 226 .operating_mode = FSL_USB2_DR_DEVICE,
228 .phy_mode = FSL_USB2_PHY_ULPI, 227 .phy_mode = FSL_USB2_PHY_ULPI,
229}; 228};
@@ -289,7 +288,7 @@ static void __init eukrea_cpuimx27_init(void)
289 imx27_add_mxc_ehci_hs(2, &usbh2_pdata); 288 imx27_add_mxc_ehci_hs(2, &usbh2_pdata);
290#endif 289#endif
291 if (!otg_mode_host) 290 if (!otg_mode_host)
292 mxc_register_device(&mxc_otg_udc_device, &otg_device_pdata); 291 imx27_add_fsl_usb2_udc(&otg_device_pdata);
293 292
294#ifdef CONFIG_MACH_EUKREA_MBIMX27_BASEBOARD 293#ifdef CONFIG_MACH_EUKREA_MBIMX27_BASEBOARD
295 eukrea_mbimx27_baseboard_init(); 294 eukrea_mbimx27_baseboard_init();
diff --git a/arch/arm/mach-imx/mach-pca100.c b/arch/arm/mach-imx/mach-pca100.c
index 683374d94024..d9e2dda437c0 100644
--- a/arch/arm/mach-imx/mach-pca100.c
+++ b/arch/arm/mach-imx/mach-pca100.c
@@ -29,7 +29,6 @@
29#include <linux/gpio.h> 29#include <linux/gpio.h>
30#include <linux/usb/otg.h> 30#include <linux/usb/otg.h>
31#include <linux/usb/ulpi.h> 31#include <linux/usb/ulpi.h>
32#include <linux/fsl_devices.h>
33 32
34#include <asm/mach/arch.h> 33#include <asm/mach/arch.h>
35#include <asm/mach-types.h> 34#include <asm/mach-types.h>
@@ -297,7 +296,7 @@ static struct mxc_usbh_platform_data usbh2_pdata __initdata = {
297}; 296};
298#endif 297#endif
299 298
300static struct fsl_usb2_platform_data otg_device_pdata = { 299static const struct fsl_usb2_platform_data otg_device_pdata __initconst = {
301 .operating_mode = FSL_USB2_DR_DEVICE, 300 .operating_mode = FSL_USB2_DR_DEVICE,
302 .phy_mode = FSL_USB2_PHY_ULPI, 301 .phy_mode = FSL_USB2_PHY_ULPI,
303}; 302};
@@ -419,7 +418,7 @@ static void __init pca100_init(void)
419#endif 418#endif
420 if (!otg_mode_host) { 419 if (!otg_mode_host) {
421 gpio_set_value(OTG_PHY_CS_GPIO, 0); 420 gpio_set_value(OTG_PHY_CS_GPIO, 0);
422 mxc_register_device(&mxc_otg_udc_device, &otg_device_pdata); 421 imx27_add_fsl_usb2_udc(&otg_device_pdata);
423 } 422 }
424 423
425 imx27_add_imx_fb(&pca100_fb_data); 424 imx27_add_imx_fb(&pca100_fb_data);