summaryrefslogtreecommitdiffstats
path: root/sys/pci/uhci_pci.c
diff options
context:
space:
mode:
authorn_hibma <n_hibma@FreeBSD.org>1999-12-03 01:34:42 +0000
committern_hibma <n_hibma@FreeBSD.org>1999-12-03 01:34:42 +0000
commitaaff10513ab1724bd046680a700be96b78f390d2 (patch)
tree28281cf6a1a9375f645bcbe6c106d2a43477e8ae /sys/pci/uhci_pci.c
parent92aa1686d24dda69a1c8e0bbf2146a9e0b9b14f6 (diff)
downloadFreeBSD-src-aaff10513ab1724bd046680a700be96b78f390d2.zip
FreeBSD-src-aaff10513ab1724bd046680a700be96b78f390d2.tar.gz
Fix the 'usb0: USB revision unknown, not supported' people have been seeing
by identifying the version in the PCI drivers. The OHCI driver just presets this to 1.0 as it is not specified in the PCI registers anywhere. This should be revisited once USB 2.0 is in wide spread use.
Diffstat (limited to 'sys/pci/uhci_pci.c')
-rw-r--r--sys/pci/uhci_pci.c25
1 files changed, 10 insertions, 15 deletions
diff --git a/sys/pci/uhci_pci.c b/sys/pci/uhci_pci.c
index bec8edb..9285174 100644
--- a/sys/pci/uhci_pci.c
+++ b/sys/pci/uhci_pci.c
@@ -155,7 +155,6 @@ uhci_pci_attach(device_t self)
void *ih;
struct resource *res;
device_t usbus;
- char *typestr;
int intr;
int legsup;
int err;
@@ -208,20 +207,16 @@ uhci_pci_attach(device_t self)
sprintf(sc->sc_vendor, "(0x%08x)", pci_get_devid(self));
}
- if (bootverbose) {
- switch(pci_read_config(self, PCI_USBREV, 4) & PCI_USBREV_MASK) {
- case PCI_USBREV_PRE_1_0:
- typestr = "pre 1.0";
- break;
- case PCI_USBREV_1_0:
- typestr = "1.0";
- break;
- default:
- typestr = "unknown";
- break;
- }
- device_printf(self, "USB version %s, chip rev. %d\n",
- typestr, pci_get_revid(self));
+ switch(pci_read_config(self, PCI_USBREV, 4) & PCI_USBREV_MASK) {
+ case PCI_USBREV_PRE_1_0:
+ sc->sc_bus.usbrev = USBREV_PRE_1_0;
+ break;
+ case PCI_USBREV_1_0:
+ sc->sc_bus.usbrev = USBREV_1_0;
+ break;
+ default:
+ sc->sc_bus.usbrev = USBREV_UNKNOWN;
+ break;
}
intr = pci_read_config(self, PCIR_INTLINE, 1);
OpenPOWER on IntegriCloud