On 2/2/2012 9:06 PM, stigge@xxxxxxxxx wrote: > This patch adds OHCI support to the LPC32xx ARM platform > > Signed-off-by: Roland Stigge <stigge@xxxxxxxxx> > > diff --git a/arch/arm/mach-lpc32xx/common.c b/arch/arm/mach-lpc32xx/common.c > index 369b152..f220eb0 100644 > --- a/arch/arm/mach-lpc32xx/common.c > +++ b/arch/arm/mach-lpc32xx/common.c > @@ -137,6 +137,31 @@ struct platform_device lpc32xx_rtc_device = { > .resource = lpc32xx_rtc_resources, > }; > > +#if defined(CONFIG_USB_OHCI_HCD) > +/* The dmamask must be set for OHCI to work */ > +static u64 ohci_dmamask = ~(u32) 0; > +static struct resource ohci_resources[] = { > + { > + .start = IO_ADDRESS(LPC32XX_USB_BASE), > + .end = IO_ADDRESS(LPC32XX_USB_BASE + 0x100), > + .flags = IORESOURCE_MEM, The resource_size() gives you (0x100 + 1) not 0x100. Are you sure .end is BASE + 0x100? or is it BASE + 0x100 - 1? sorry if I confused you. Thanks, Pavan > + }, { > + .start = IRQ_LPC32XX_USB_HOST, > + .flags = IORESOURCE_IRQ, > + }, > +}; > +struct platform_device lpc32xx_ohci_device = { > + .name = "usb-ohci", > + .id = -1, > + .dev = { > + .dma_mask = &ohci_dmamask, > + .coherent_dma_mask = 0xFFFFFFFF, > + }, > + .num_resources = ARRAY_SIZE(ohci_resources), > + .resource = ohci_resources, > +}; > +#endif -- Sent by a consultant of the Qualcomm Innovation Center, Inc. The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum. -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html