Module Name:    src
Committed By:   riastradh
Date:           Sat May 29 16:49:30 UTC 2021

Modified Files:
        src/sys/dev/usb: xhci.c

Log Message:
xhci(4): Wait USB_RESUME_WAIT ms, not 20 ms.

Better to use the named constant, and although the spec says 20 ms is
enough, apparently for some devices it's not.


To generate a diff of this commit:
cvs rdiff -u -r1.142 -r1.143 src/sys/dev/usb/xhci.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/usb/xhci.c
diff -u src/sys/dev/usb/xhci.c:1.142 src/sys/dev/usb/xhci.c:1.143
--- src/sys/dev/usb/xhci.c:1.142	Thu May 27 11:09:15 2021
+++ src/sys/dev/usb/xhci.c	Sat May 29 16:49:30 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: xhci.c,v 1.142 2021/05/27 11:09:15 skrll Exp $	*/
+/*	$NetBSD: xhci.c,v 1.143 2021/05/29 16:49:30 riastradh Exp $	*/
 
 /*
  * Copyright (c) 2013 Jonathan A. Kollasch
@@ -34,7 +34,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: xhci.c,v 1.142 2021/05/27 11:09:15 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: xhci.c,v 1.143 2021/05/29 16:49:30 riastradh Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_usb.h"
@@ -1027,7 +1027,7 @@ xhci_resume(device_t self, const pmf_qua
 				v |= XHCI_PS_LWS;
 				v |= XHCI_PS_PLS_SET(XHCI_PS_PLS_SETRESUME);
 				xhci_op_write_4(sc, port, v);
-				usb_delay_ms(&sc->sc_bus, 20);
+				usb_delay_ms(&sc->sc_bus, USB_RESUME_WAIT);
 			} else {
 				KASSERT(sc->sc_bus.ub_revision > USBREV_2_0);
 			}

Reply via email to