NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: kern/46696: uhub disables port where USB keyboard attached



Does this patch against -current fix the problem?

Thanks,
Nick
Index: sys/dev/usb/usb_subr.c
===================================================================
RCS file: /cvsroot/src/sys/dev/usb/usb_subr.c,v
retrieving revision 1.189
diff -u -p -u -r1.189 usb_subr.c
--- sys/dev/usb/usb_subr.c      22 Jan 2013 14:01:19 -0000      1.189
+++ sys/dev/usb/usb_subr.c      19 Mar 2013 08:03:03 -0000
@@ -1133,7 +1133,12 @@ usbd_new_device(device_t parent, usbd_bu
         * (which uses 64 bytes so it shouldn't be less),
         * highspeed devices must support 64 byte packets anyway
         */
-       USETW(dev->def_ep_desc.wMaxPacketSize, 64);
+
+       if (speed == USB_SPEED_HIGH || speed == USB_SPEED_FULL)
+               USETW(dev->def_ep_desc.wMaxPacketSize, 64);
+       else
+               USETW(dev->def_ep_desc.wMaxPacketSize, USB_MAX_IPACKET);
+       
        dev->def_ep_desc.bInterval = 0;
 
        /* doesn't matter, just don't let it uninitialized */


Home | Main Index | Thread Index | Old Index