diff options
author | Brad Smith <brad@cvs.openbsd.org> | 2005-12-03 03:40:53 +0000 |
---|---|---|
committer | Brad Smith <brad@cvs.openbsd.org> | 2005-12-03 03:40:53 +0000 |
commit | 3744d1bf4de374ece69626cf0c801ad33a491de4 (patch) | |
tree | e68b74dd83b035d768bb49650b955008944053dc /sys | |
parent | b3c04098cf7264c08a88143453690a416b691c3b (diff) |
Allow strings descriptor 0 to be fetched. It's the default language index.
From augustss NetBSD
ok dlg@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/usb/ehci.c | 7 | ||||
-rw-r--r-- | sys/dev/usb/ohci.c | 5 | ||||
-rw-r--r-- | sys/dev/usb/uhci.c | 5 |
3 files changed, 13 insertions, 4 deletions
diff --git a/sys/dev/usb/ehci.c b/sys/dev/usb/ehci.c index 4f619730749..7e459c04ed0 100644 --- a/sys/dev/usb/ehci.c +++ b/sys/dev/usb/ehci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ehci.c,v 1.52 2005/11/21 18:16:42 millert Exp $ */ +/* $OpenBSD: ehci.c,v 1.53 2005/12/03 03:40:52 brad Exp $ */ /* $NetBSD: ehci.c,v 1.66 2004/06/30 03:11:56 mycroft Exp $ */ /* @@ -479,7 +479,7 @@ ehci_init(ehci_softc_t *sc) /* Turn on controller */ EOWRITE4(sc, EHCI_USBCMD, - EHCI_CMD_ITC_2 | /* 2 microframes */ + EHCI_CMD_ITC_2 | /* 2 microframes interrupt delay */ (EOREAD4(sc, EHCI_USBCMD) & EHCI_CMD_FLS_M) | EHCI_CMD_ASE | EHCI_CMD_PSE | @@ -1760,6 +1760,9 @@ ehci_root_ctrl_start(usbd_xfer_handle xfer) *(u_int8_t *)buf = 0; totlen = 1; switch (value & 0xff) { + case 0: /* Language table */ + totlen = ehci_str(buf, len, "\001"); + break; case 1: /* Vendor */ totlen = ehci_str(buf, len, sc->sc_vendor); break; diff --git a/sys/dev/usb/ohci.c b/sys/dev/usb/ohci.c index 88ff878ee35..f5720aadf12 100644 --- a/sys/dev/usb/ohci.c +++ b/sys/dev/usb/ohci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ohci.c,v 1.64 2005/11/21 18:16:42 millert Exp $ */ +/* $OpenBSD: ohci.c,v 1.65 2005/12/03 03:40:52 brad Exp $ */ /* $NetBSD: ohci.c,v 1.139 2003/02/22 05:24:16 tsutsui Exp $ */ /* $FreeBSD: src/sys/dev/usb/ohci.c,v 1.22 1999/11/17 22:33:40 n_hibma Exp $ */ @@ -2476,6 +2476,9 @@ ohci_root_ctrl_start(usbd_xfer_handle xfer) *(u_int8_t *)buf = 0; totlen = 1; switch (value & 0xff) { + case 0: /* Language table */ + totlen = ohci_str(buf, len, "\001"); + break; case 1: /* Vendor */ totlen = ohci_str(buf, len, sc->sc_vendor); break; diff --git a/sys/dev/usb/uhci.c b/sys/dev/usb/uhci.c index f4d36abd899..4e285c6b094 100644 --- a/sys/dev/usb/uhci.c +++ b/sys/dev/usb/uhci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: uhci.c,v 1.41 2005/11/21 18:16:43 millert Exp $ */ +/* $OpenBSD: uhci.c,v 1.42 2005/12/03 03:40:52 brad Exp $ */ /* $NetBSD: uhci.c,v 1.172 2003/02/23 04:19:26 simonb Exp $ */ /* $FreeBSD: src/sys/dev/usb/uhci.c,v 1.33 1999/11/17 22:33:41 n_hibma Exp $ */ @@ -3183,6 +3183,9 @@ uhci_root_ctrl_start(usbd_xfer_handle xfer) *(u_int8_t *)buf = 0; totlen = 1; switch (value & 0xff) { + case 0: /* Language table */ + totlen = uhci_str(buf, len, "\001"); + break; case 1: /* Vendor */ totlen = uhci_str(buf, len, sc->sc_vendor); break; |