2 * linux/arch/arm/mach-omap2/board-2430sdp-usb.c
4 * Copyright (C) 2007 MontaVista Software, Inc. <source@mvista.com>
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License version 2 as
9 * published by the Free Software Foundation.
12 #include <linux/types.h>
13 #include <linux/errno.h>
14 #include <linux/delay.h>
15 #include <linux/platform_device.h>
16 #include <linux/usb/musb.h>
18 #include <asm/arch/hardware.h>
19 #include <asm/arch/usb.h>
21 static struct resource musb_resources[] = {
23 .start = OMAP243X_HS_BASE,
24 .end = OMAP243X_HS_BASE + SZ_8K,
25 .flags = IORESOURCE_MEM,
27 [1] = { /* general IRQ */
28 .start = INT_243X_HS_USB_MC,
29 .flags = IORESOURCE_IRQ,
32 .start = INT_243X_HS_USB_DMA,
33 .flags = IORESOURCE_IRQ,
37 static struct musb_hdrc_platform_data musb_plat = {
38 #ifdef CONFIG_USB_MUSB_OTG
40 #elif defined(CONFIG_USB_MUSB_HDRC_HCD)
42 #elif defined(CONFIG_USB_GADGET_MUSB_HDRC)
43 .mode = MUSB_PERIPHERAL,
48 static u64 musb_dmamask = ~(u32)0;
50 static struct platform_device musb_device = {
54 .dma_mask = &musb_dmamask,
55 .coherent_dma_mask = 0xffffffff,
56 .platform_data = &musb_plat,
58 .num_resources = ARRAY_SIZE(musb_resources),
59 .resource = musb_resources,
62 void __init sdp2430_usb_init(void)
64 if (platform_device_register(&musb_device) < 0) {
65 printk(KERN_ERR "Unable to register HS-USB (MUSB) device\n");