diff options
author | Daniel Mack <daniel@caiaq.de> | 2009-03-13 16:37:11 +0100 |
---|---|---|
committer | Eric Miao <eric.miao@marvell.com> | 2009-03-23 09:57:54 +0800 |
commit | 42e07ad7fc111bde5cd6c0e5bd7085b4cecf96b7 (patch) | |
tree | 43f22ae375860ae6123926a58f89212afefed157 /arch/arm/mach-pxa | |
parent | ebc046c2a3544ba4f55512a218a4084522473bcd (diff) | |
download | op-kernel-dev-42e07ad7fc111bde5cd6c0e5bd7085b4cecf96b7.zip op-kernel-dev-42e07ad7fc111bde5cd6c0e5bd7085b4cecf96b7.tar.gz |
[ARM] pxa: add USB support for Colibri PXA300
This adds support for USB OHCI for Toradex' Colibri PXA300 modules as
connected on the evaluation board.
Signed-off-by: Daniel Mack <daniel@caiaq.de>
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Diffstat (limited to 'arch/arm/mach-pxa')
-rw-r--r-- | arch/arm/mach-pxa/colibri-pxa300.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/arch/arm/mach-pxa/colibri-pxa300.c b/arch/arm/mach-pxa/colibri-pxa300.c index 7cc4249..f1f2486 100644 --- a/arch/arm/mach-pxa/colibri-pxa300.c +++ b/arch/arm/mach-pxa/colibri-pxa300.c @@ -22,6 +22,7 @@ #include <mach/pxa300.h> #include <mach/colibri.h> #include <mach/mmc.h> +#include <mach/ohci.h> #include "generic.h" #include "devices.h" @@ -41,6 +42,11 @@ static mfp_cfg_t colibri_pxa300_pin_config[] __initdata = { GPIO5_MMC1_DAT2, GPIO6_MMC1_DAT3, #endif + +#if defined (CONFIG_USB_OHCI_HCD) || defined(CONFIG_USB_OHCI_HCD_MODULE) + GPIO0_2_USBH_PEN, + GPIO1_2_USBH_PWR, +#endif }; #if defined(CONFIG_AX88796) @@ -137,12 +143,27 @@ static void __init colibri_pxa300_init_mmc(void) static inline void colibri_pxa300_init_mmc(void) {} #endif /* CONFIG_MMC_PXA */ +#if defined(CONFIG_USB_OHCI_HCD) || defined(CONFIG_USB_OHCI_HCD_MODULE) +static struct pxaohci_platform_data colibri_pxa300_ohci_info = { + .port_mode = PMM_GLOBAL_MODE, + .flags = ENABLE_PORT1 | POWER_CONTROL_LOW | POWER_SENSE_LOW, +}; + +static void __init colibri_pxa300_init_ohci(void) +{ + pxa_set_ohci_info(&colibri_pxa300_ohci_info); +} +#else +static inline void colibri_pxa300_init_ohci(void) {} +#endif /* CONFIG_USB_OHCI_HCD || CONFIG_USB_OHCI_HCD_MODULE */ + static void __init colibri_pxa300_init(void) { set_irq_type(COLIBRI_PXA300_ETH_IRQ, IRQ_TYPE_EDGE_FALLING); pxa3xx_mfp_config(ARRAY_AND_SIZE(colibri_pxa300_pin_config)); platform_add_devices(ARRAY_AND_SIZE(colibri_pxa300_devices)); colibri_pxa300_init_mmc(); + colibri_pxa300_init_ohci(); } MACHINE_START(COLIBRI300, "Toradex Colibri PXA300") |