summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorJacob Meuser <jakemsr@cvs.openbsd.org>2009-11-24 00:31:14 +0000
committerJacob Meuser <jakemsr@cvs.openbsd.org>2009-11-24 00:31:14 +0000
commit8d27fa045af5daa13f832a3c46fcaa53ded14a7a (patch)
treeb84e5cd353a70ab34e3d7edebfe0e58ef59d39d6 /sys
parentfcd72d51a223ebafe30df2b9ea785d80c4483d1d (diff)
fix hardware polling interval calculation. uaudio on my Logitech webcam
now records properly. ok miod, yuo
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/usb/ehci.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/usb/ehci.c b/sys/dev/usb/ehci.c
index 3b2274ca27d..0718dac34f2 100644
--- a/sys/dev/usb/ehci.c
+++ b/sys/dev/usb/ehci.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ehci.c,v 1.104 2009/11/04 19:14:10 kettenis Exp $ */
+/* $OpenBSD: ehci.c,v 1.105 2009/11/24 00:31:13 jakemsr Exp $ */
/* $NetBSD: ehci.c,v 1.66 2004/06/30 03:11:56 mycroft Exp $ */
/*
@@ -3684,7 +3684,7 @@ ehci_device_isoc_start(usbd_xfer_handle xfer)
* the entire frame table. To within 4 frames, to allow some leeway
* on either side of where the hc currently is.
*/
- if ((1 << (epipe->pipe.endpoint->edesc->bInterval)) *
+ if ((1 << (epipe->pipe.endpoint->edesc->bInterval - 1)) *
xfer->nframes >= (sc->sc_flsize - 4) * 8) {
printf("ehci: isoc descriptor requested that spans the entire "
"frametable, too many frames\n");
@@ -3854,7 +3854,7 @@ ehci_device_isoc_start(usbd_xfer_handle xfer)
frindex &= (sc->sc_flsize - 1);
/* Whats the frame interval? */
- i = (1 << epipe->pipe.endpoint->edesc->bInterval);
+ i = (1 << (epipe->pipe.endpoint->edesc->bInterval - 1));
if (i / 8 == 0)
i = 1;
else