aboutsummaryrefslogtreecommitdiff
path: root/lib/libusb
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2013-07-25 13:57:29 +1000
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2013-08-06 16:00:29 +1000
commit225b8b0e3ae3256d8471d027436aad5d3e1e2c73 (patch)
tree5bd9e1f7f291c6b8ead312c3f0371520af6f0a10 /lib/libusb
parent14bca6ff9ac595d7b4405835c4fa979440c64965 (diff)
downloadSLOF-225b8b0e3ae3256d8471d027436aad5d3e1e2c73.zip
SLOF-225b8b0e3ae3256d8471d027436aad5d3e1e2c73.tar.gz
SLOF-225b8b0e3ae3256d8471d027436aad5d3e1e2c73.tar.bz2
usb-ohci: Add a reset when closing the OHCI
Or it will continue DMA'ing which is not a good idea. On recent qemu's that add proper DMA error handling, it will get into error state. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'lib/libusb')
-rw-r--r--lib/libusb/usb-ohci.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/libusb/usb-ohci.c b/lib/libusb/usb-ohci.c
index 75d833e..9315c8c 100644
--- a/lib/libusb/usb-ohci.c
+++ b/lib/libusb/usb-ohci.c
@@ -314,6 +314,7 @@ static void ohci_exit(struct usb_hcd_dev *hcidev)
return;
}
ohcd = hcidev->priv;
+ ohci_hcd_reset(ohcd->regs);
write_reg32(&ohcd->regs->hcca, cpu_to_le32(0));
SLOF_dma_map_out(ohcd->pool_phys, ohcd->pool, OHCI_PIPE_POOL_SIZE);
SLOF_dma_free(ohcd->pool, OHCI_PIPE_POOL_SIZE);