diff options
author | Roland Stigge <stigge@antcom.de> | 2012-03-12 17:23:43 -0400 |
---|---|---|
committer | Roland Stigge <stigge@antcom.de> | 2012-03-13 16:15:50 -0400 |
commit | 48a5dedfa78899dad50b3b4ae30f07e27e6591ab (patch) | |
tree | 3dab55b1f4e4dd755b67887555489541f688aae8 /arch/arm/mach-lpc32xx/common.c | |
parent | a7e4c6a7145ee375a688e1701ae4c975d6c6419a (diff) |
ARM: LPC32xx: USB Support
This patch adds OHCI support to the LPC32xx ARM platform. Besides the trivial
addition of platform "usb-ohci" support, fixes for the USB PLL have been added
to arch/arm/mach-lpc32xx/clock.c, ported from NXP's lpclinux.com.
(This is the mach-lpc32xx specific part, the USB subsystem specific changes are
in a separate patch for the USB maintainers.)
Signed-off-by: Roland Stigge <stigge@antcom.de>
Diffstat (limited to 'arch/arm/mach-lpc32xx/common.c')
-rw-r--r-- | arch/arm/mach-lpc32xx/common.c | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/arch/arm/mach-lpc32xx/common.c b/arch/arm/mach-lpc32xx/common.c index 6c76bb36559b..11c900857b1b 100644 --- a/arch/arm/mach-lpc32xx/common.c +++ b/arch/arm/mach-lpc32xx/common.c | |||
@@ -160,6 +160,32 @@ struct platform_device lpc32xx_adc_device = { | |||
160 | }; | 160 | }; |
161 | 161 | ||
162 | /* | 162 | /* |
163 | * USB support | ||
164 | */ | ||
165 | /* The dmamask must be set for OHCI to work */ | ||
166 | static u64 ohci_dmamask = ~(u32) 0; | ||
167 | static struct resource ohci_resources[] = { | ||
168 | { | ||
169 | .start = IO_ADDRESS(LPC32XX_USB_BASE), | ||
170 | .end = IO_ADDRESS(LPC32XX_USB_BASE + 0x100 - 1), | ||
171 | .flags = IORESOURCE_MEM, | ||
172 | }, { | ||
173 | .start = IRQ_LPC32XX_USB_HOST, | ||
174 | .flags = IORESOURCE_IRQ, | ||
175 | }, | ||
176 | }; | ||
177 | struct platform_device lpc32xx_ohci_device = { | ||
178 | .name = "usb-ohci", | ||
179 | .id = -1, | ||
180 | .dev = { | ||
181 | .dma_mask = &ohci_dmamask, | ||
182 | .coherent_dma_mask = 0xFFFFFFFF, | ||
183 | }, | ||
184 | .num_resources = ARRAY_SIZE(ohci_resources), | ||
185 | .resource = ohci_resources, | ||
186 | }; | ||
187 | |||
188 | /* | ||
163 | * Returns the unique ID for the device | 189 | * Returns the unique ID for the device |
164 | */ | 190 | */ |
165 | void lpc32xx_get_uid(u32 devid[4]) | 191 | void lpc32xx_get_uid(u32 devid[4]) |