summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGanael LAPLANCHE <martymac@FreeBSD.org>2020-10-14 06:25:55 +0000
committerGanael LAPLANCHE <martymac@FreeBSD.org>2020-10-14 06:25:55 +0000
commit5a0826ac57e37ec226ec61c1bfa9d74a28165c89 (patch)
tree565b3c8275f384704493b252e1ac6533871a687b
parent8e83334bb67d06323f95546a9bad2fdb939659e5 (diff)
downloadsrc-test2-5a0826ac57e37ec226ec61c1bfa9d74a28165c89.tar.gz
src-test2-5a0826ac57e37ec226ec61c1bfa9d74a28165c89.zip
MFS r365964:
Allow slow USB devices to be given more time to return their USB descriptors, like Logitech HD Pro Webcam C920. PR: 248926 Approved by: re (gjb), hselasky
Notes
Notes: svn path=/releng/12.2/; revision=366693
-rw-r--r--sys/dev/usb/usb_request.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/dev/usb/usb_request.c b/sys/dev/usb/usb_request.c
index 73e9874cb466..32bf0a9435ef 100644
--- a/sys/dev/usb/usb_request.c
+++ b/sys/dev/usb/usb_request.c
@@ -721,7 +721,8 @@ done:
case USB_ERR_CANCELLED:
break;
default:
- DPRINTF("I/O error - waiting a bit for TT cleanup\n");
+ DPRINTF("error=%s - waiting a bit for TT cleanup\n",
+ usbd_errstr(err));
usb_pause_mtx(mtx, hz / 16);
break;
}
@@ -1010,7 +1011,7 @@ usbd_req_get_desc(struct usb_device *udev,
USETW(req.wLength, min_len);
err = usbd_do_request_flags(udev, mtx, &req,
- desc, 0, NULL, 500 /* ms */);
+ desc, 0, NULL, 1000 /* ms */);
if (err != 0 && err != USB_ERR_TIMEOUT &&
min_len != max_len) {
@@ -1021,7 +1022,7 @@ usbd_req_get_desc(struct usb_device *udev,
USETW(req.wLength, max_len);
err = usbd_do_request_flags(udev, mtx, &req,
- desc, USB_SHORT_XFER_OK, NULL, 500 /* ms */);
+ desc, USB_SHORT_XFER_OK, NULL, 1000 /* ms */);
if (err == 0) {
/* verify length */