summaryrefslogtreecommitdiff
path: root/sys/dev/usb
diff options
context:
space:
mode:
authorJonathan Matthew <jmatthew@cvs.openbsd.org>2015-06-08 00:58:24 +0000
committerJonathan Matthew <jmatthew@cvs.openbsd.org>2015-06-08 00:58:24 +0000
commitc22794745546ab74c247689b93f7152e0e305073 (patch)
tree498d110be6cae173e9014086817186b378e8687a /sys/dev/usb
parented00d0eb1b67cd091d0c6dca21f093593b62ee36 (diff)
refuse to do polled isochronous transfers, as other usb controller drivers do
requested by mpi@
Diffstat (limited to 'sys/dev/usb')
-rw-r--r--sys/dev/usb/dwc2/dwc2.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/dev/usb/dwc2/dwc2.c b/sys/dev/usb/dwc2/dwc2.c
index 09c2a2ce252..c5d98b35a51 100644
--- a/sys/dev/usb/dwc2/dwc2.c
+++ b/sys/dev/usb/dwc2/dwc2.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dwc2.c,v 1.26 2015/06/08 00:46:33 jmatthew Exp $ */
+/* $OpenBSD: dwc2.c,v 1.27 2015/06/08 00:58:23 jmatthew Exp $ */
/* $NetBSD: dwc2.c,v 1.32 2014/09/02 23:26:20 macallan Exp $ */
/*-
@@ -1221,14 +1221,15 @@ dwc2_device_isoc_start(struct usbd_xfer *xfer)
struct dwc2_softc *sc = DWC2_DPIPE2SC(dpipe);
usbd_status err;
+ /* Why would you do that anyway? */
+ if (sc->sc_bus.use_polling)
+ return (USBD_INVAL);
+
mtx_enter(&sc->sc_lock);
xfer->status = USBD_IN_PROGRESS;
err = dwc2_device_start(xfer);
mtx_leave(&sc->sc_lock);
- if (sc->sc_bus.use_polling)
- dwc2_waitintr(sc, xfer);
-
return err;
}