summaryrefslogtreecommitdiffstats
path: root/drivers/usb/gadget
diff options
context:
space:
mode:
authorRussell King <rmk@dyn-67.arm.linux.org.uk>2008-07-12 22:43:36 +0200
committerRussell King <rmk+kernel@arm.linux.org.uk>2008-07-12 22:43:36 +0200
commit5a58d4bb66b1d68e4b9319dd5b89078bad2a7f64 (patch)
tree7e3c7dd69ba19b41d11ff8f08f2906443a72a5e6 /drivers/usb/gadget
parentMerge branch 'pxa-tosa' into pxa (diff)
parentSupport for LCD on e740 e750 e400 and e800 e-series PDAs (diff)
downloadlinux-5a58d4bb66b1d68e4b9319dd5b89078bad2a7f64.tar.xz
linux-5a58d4bb66b1d68e4b9319dd5b89078bad2a7f64.zip
Merge branch 'eseries' into pxa
Conflicts: arch/arm/mach-pxa/Makefile
Diffstat (limited to 'drivers/usb/gadget')
-rw-r--r--drivers/usb/gadget/pxa25x_udc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/usb/gadget/pxa25x_udc.c b/drivers/usb/gadget/pxa25x_udc.c
index 031dceb93023..5d50031938ab 100644
--- a/drivers/usb/gadget/pxa25x_udc.c
+++ b/drivers/usb/gadget/pxa25x_udc.c
@@ -152,9 +152,10 @@ static int is_vbus_present(void)
static void pullup_off(void)
{
struct pxa2xx_udc_mach_info *mach = the_controller->mach;
+ int off_level = mach->gpio_pullup_inverted;
if (mach->gpio_pullup)
- gpio_set_value(mach->gpio_pullup, 0);
+ gpio_set_value(mach->gpio_pullup, off_level);
else if (mach->udc_command)
mach->udc_command(PXA2XX_UDC_CMD_DISCONNECT);
}
@@ -162,9 +163,10 @@ static void pullup_off(void)
static void pullup_on(void)
{
struct pxa2xx_udc_mach_info *mach = the_controller->mach;
+ int on_level = !mach->gpio_pullup_inverted;
if (mach->gpio_pullup)
- gpio_set_value(mach->gpio_pullup, 1);
+ gpio_set_value(mach->gpio_pullup, on_level);
else if (mach->udc_command)
mach->udc_command(PXA2XX_UDC_CMD_CONNECT);
}