summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormpi <mpi@openbsd.org>2015-01-11 15:41:16 +0000
committermpi <mpi@openbsd.org>2015-01-11 15:41:16 +0000
commit2fecb3feed119c60a367f399a1718a3d859f04a3 (patch)
tree4627289876e208a407194e2048378dacc0211257
parentUse the softc-specific function pointers for bcopy() and bzero() in iestart(), (diff)
downloadwireguard-openbsd-2fecb3feed119c60a367f399a1718a3d859f04a3.tar.xz
wireguard-openbsd-2fecb3feed119c60a367f399a1718a3d859f04a3.zip
There's no simple way so check for DMA buffer overrun with isochronous
transfers, so skip the check for such xfers for the moment. Issue reported by Ingo Feinerer and fix confirmed by Jan Stary.
-rw-r--r--sys/dev/usb/usbdi.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/usb/usbdi.c b/sys/dev/usb/usbdi.c
index 53b9240c4cf..7db61f201c0 100644
--- a/sys/dev/usb/usbdi.c
+++ b/sys/dev/usb/usbdi.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: usbdi.c,v 1.77 2015/01/09 12:15:48 mpi Exp $ */
+/* $OpenBSD: usbdi.c,v 1.78 2015/01/11 15:41:16 mpi Exp $ */
/* $NetBSD: usbdi.c,v 1.103 2002/09/27 15:37:38 provos Exp $ */
/* $FreeBSD: src/sys/dev/usb/usbdi.c,v 1.28 1999/11/17 22:33:49 n_hibma Exp $ */
@@ -732,7 +732,7 @@ usb_transfer_complete(struct usbd_xfer *xfer)
pipe->running = 0;
#ifdef DIAGNOSTIC
- if (xfer->actlen > xfer->length) {
+ if (xfer->actlen > xfer->length && xfer->length != 0) {
printf("%s: actlen > len %u > %u\n", __func__, xfer->actlen,
xfer->length);
xfer->actlen = xfer->length;