summaryrefslogtreecommitdiffstats
path: root/sys/dev/usb/controller/uhci.c
diff options
context:
space:
mode:
authorhselasky <hselasky@FreeBSD.org>2012-10-24 07:23:29 +0000
committerhselasky <hselasky@FreeBSD.org>2012-10-24 07:23:29 +0000
commitddc1ceecb37fd6540ef54cf3194f65a36fd330e0 (patch)
treeb2f5dc26223f979365eae70ebbdf09f90d4c8dbd /sys/dev/usb/controller/uhci.c
parent63a4ea167200b31a05ebe40e5f607b26ec0a7c78 (diff)
downloadFreeBSD-src-ddc1ceecb37fd6540ef54cf3194f65a36fd330e0.zip
FreeBSD-src-ddc1ceecb37fd6540ef54cf3194f65a36fd330e0.tar.gz
Make several timing parameters of the USB enumeration sequence tuneable.
Also update the port reset time from 250ms to 50ms. Some USB devices have a hard limit in hardware at 222ms for the port reset time and will not enumerate unless this delay is closer to the usb.org defined value. This patch can fix enumeration with some USB devices. Tested by: Guido van Rooij Submitted by: Nick Hibma MFC after: 1 week
Diffstat (limited to 'sys/dev/usb/controller/uhci.c')
-rw-r--r--sys/dev/usb/controller/uhci.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/usb/controller/uhci.c b/sys/dev/usb/controller/uhci.c
index 680aac2..39588d4 100644
--- a/sys/dev/usb/controller/uhci.c
+++ b/sys/dev/usb/controller/uhci.c
@@ -2393,7 +2393,7 @@ uhci_portreset(uhci_softc_t *sc, uint16_t index)
UWRITE2(sc, port, x | UHCI_PORTSC_PR);
usb_pause_mtx(&sc->sc_bus.bus_mtx,
- USB_MS_TO_TICKS(USB_PORT_ROOT_RESET_DELAY));
+ USB_MS_TO_TICKS(usb_port_root_reset_delay));
DPRINTFN(4, "uhci port %d reset, status0 = 0x%04x\n",
index, UREAD2(sc, port));
@@ -2421,7 +2421,7 @@ uhci_portreset(uhci_softc_t *sc, uint16_t index)
for (lim = 0; lim < 12; lim++) {
usb_pause_mtx(&sc->sc_bus.bus_mtx,
- USB_MS_TO_TICKS(USB_PORT_RESET_DELAY));
+ USB_MS_TO_TICKS(usb_port_reset_delay));
x = UREAD2(sc, port);
OpenPOWER on IntegriCloud