diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-07-05 15:09:27 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-07-05 15:09:27 -0700 |
commit | 979eef33267ec230b820f4f76b2103e8b567fa57 (patch) | |
tree | 626d47f5c575424c90965ddf5ff35c70d09e0948 /drivers/usb/musb/musb_host.c | |
parent | e765bf84d59257d3c4f948fbce426ea3565e83ad (diff) | |
parent | 2ed9127cff9a255b7671b8d3d938109f68a87961 (diff) | |
download | linux-979eef33267ec230b820f4f76b2103e8b567fa57.tar.bz2 |
Merge tag 'musb-for-v3.6' of git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb into usb-next
usb: musb: patches for v3.6 merge window
Just two patches here:
First we have a fix to disable DMA in case DMA channel
request fails.
Second, there's a fix for situations where the user
kills musb (by rmmod or any other means) while a
transfer is on the fly. In such cases, we could be
led into a NULL pointer dereference due to endpoint
being disabled and endpoint descriptor being NULL.
Diffstat (limited to 'drivers/usb/musb/musb_host.c')
-rw-r--r-- | drivers/usb/musb/musb_host.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/usb/musb/musb_host.c b/drivers/usb/musb/musb_host.c index e090c799d87b..4bb717d0bd41 100644 --- a/drivers/usb/musb/musb_host.c +++ b/drivers/usb/musb/musb_host.c @@ -1746,7 +1746,11 @@ void musb_host_rx(struct musb *musb, u8 epnum) c->channel_release(dma); hw_ep->rx_channel = NULL; dma = NULL; - /* REVISIT reset CSR */ + val = musb_readw(epio, MUSB_RXCSR); + val &= ~(MUSB_RXCSR_DMAENAB + | MUSB_RXCSR_H_AUTOREQ + | MUSB_RXCSR_AUTOCLEAR); + musb_writew(epio, MUSB_RXCSR, val); } } #endif /* Mentor DMA */ |