From 8ac3e894997c1fc73b96c7eeb2b94aa925e02cd1 Mon Sep 17 00:00:00 2001 From: Ian Molton Date: Thu, 10 Jul 2008 20:16:35 +0100 Subject: [PATCH] --- yaml --- r: 105146 b: refs/heads/master c: 32584c86b26e503dcd7228ab1c67a1e4ce9b48c4 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/arch/arm/mach-pxa/Makefile | 2 +- trunk/arch/arm/mach-pxa/eseries_udc.c | 57 +++++++++++++++++++++++++++ 3 files changed, 59 insertions(+), 2 deletions(-) create mode 100644 trunk/arch/arm/mach-pxa/eseries_udc.c diff --git a/[refs] b/[refs] index 3954f1d43a31..436ae78a0e8e 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 8fb105f5cc7f31ff37755945378a668f4c21590e +refs/heads/master: 32584c86b26e503dcd7228ab1c67a1e4ce9b48c4 diff --git a/trunk/arch/arm/mach-pxa/Makefile b/trunk/arch/arm/mach-pxa/Makefile index c4dfbe87fc4e..9d4c3931d0e9 100644 --- a/trunk/arch/arm/mach-pxa/Makefile +++ b/trunk/arch/arm/mach-pxa/Makefile @@ -36,7 +36,7 @@ obj-$(CONFIG_MACH_PCM990_BASEBOARD) += pcm990-baseboard.o obj-$(CONFIG_MACH_TOSA) += tosa.o obj-$(CONFIG_MACH_EM_X270) += em-x270.o obj-$(CONFIG_MACH_MAGICIAN) += magician.o -obj-$(CONFIG_ARCH_PXA_ESERIES) += eseries.o +obj-$(CONFIG_ARCH_PXA_ESERIES) += eseries.o eseries_udc.o ifeq ($(CONFIG_MACH_ZYLONITE),y) obj-y += zylonite.o diff --git a/trunk/arch/arm/mach-pxa/eseries_udc.c b/trunk/arch/arm/mach-pxa/eseries_udc.c new file mode 100644 index 000000000000..362847a10998 --- /dev/null +++ b/trunk/arch/arm/mach-pxa/eseries_udc.c @@ -0,0 +1,57 @@ +/* + * UDC functions for the Toshiba e-series PDAs + * + * Copyright (c) Ian Molton 2003 + * + * This file is licensed under + * the terms of the GNU General Public License version 2. This program + * is licensed "as is" without any warranty of any kind, whether express + * or implied. + * + */ + +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +/* local PXA generic code */ +#include "generic.h" + +static struct pxa2xx_udc_mach_info e7xx_udc_mach_info = { + .gpio_vbus = GPIO_E7XX_USB_DISC, + .gpio_pullup = GPIO_E7XX_USB_PULLUP, + .gpio_pullup_inverted = 1 +}; + +static struct pxa2xx_udc_mach_info e800_udc_mach_info = { + .gpio_vbus = GPIO_E800_USB_DISC, + .gpio_pullup = GPIO_E800_USB_PULLUP, + .gpio_pullup_inverted = 1 +}; + +static int __init eseries_udc_init(void) +{ + if (machine_is_e330() || machine_is_e350() || + machine_is_e740() || machine_is_e750() || + machine_is_e400()) + pxa_set_udc_info(&e7xx_udc_mach_info); + else if (machine_is_e800()) + pxa_set_udc_info(&e800_udc_mach_info); + + return 0; +} + +module_init(eseries_udc_init); + +MODULE_AUTHOR("Ian Molton "); +MODULE_DESCRIPTION("eseries UDC support"); +MODULE_LICENSE("GPLv2");