diff options
author | karl beldan <karl.beldan@gmail.com> | 2008-05-16 05:30:22 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2008-05-20 17:14:14 -0400 |
commit | 3f886620742edd4e7e037d7d9349be69df0ce59b (patch) | |
tree | dcaa7e3d78cec7b859a696c73b6594be5031cb36 /drivers/usb | |
parent | 1b2d23d49cf4b4b1fe3b43d3ffd6077fc4ee9ac6 (diff) |
USB: pxa27x_udc - Fix Oops
udc_disable oopses dereferencing udc_command.
Signed-off-by: Karl Beldan <karl.beldan@gmail.com>
Acked-by: Robert Jarzmik <rjarzmik@free.fr>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/gadget/pxa27x_udc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/usb/gadget/pxa27x_udc.c b/drivers/usb/gadget/pxa27x_udc.c index 499b7a23f351..e02bfd4df3a6 100644 --- a/drivers/usb/gadget/pxa27x_udc.c +++ b/drivers/usb/gadget/pxa27x_udc.c | |||
@@ -1526,7 +1526,8 @@ static void udc_disable(struct pxa_udc *udc) | |||
1526 | 1526 | ||
1527 | ep0_idle(udc); | 1527 | ep0_idle(udc); |
1528 | udc->gadget.speed = USB_SPEED_UNKNOWN; | 1528 | udc->gadget.speed = USB_SPEED_UNKNOWN; |
1529 | udc->mach->udc_command(PXA2XX_UDC_CMD_DISCONNECT); | 1529 | if (udc->mach->udc_command) |
1530 | udc->mach->udc_command(PXA2XX_UDC_CMD_DISCONNECT); | ||
1530 | } | 1531 | } |
1531 | 1532 | ||
1532 | /** | 1533 | /** |