summaryrefslogtreecommitdiffstats
path: root/sys/pci
diff options
context:
space:
mode:
authorn_hibma <n_hibma@FreeBSD.org>1999-11-22 03:34:43 +0000
committern_hibma <n_hibma@FreeBSD.org>1999-11-22 03:34:43 +0000
commitce990701454da56eade1bde3de50ba12d287441c (patch)
treecb45f05a948eb97aafad7adce8063c3796ea0530 /sys/pci
parent2365e84cddf9b1dba8720a87a6e9500fe654ba8f (diff)
downloadFreeBSD-src-ce990701454da56eade1bde3de50ba12d287441c.zip
FreeBSD-src-ce990701454da56eade1bde3de50ba12d287441c.tar.gz
Move the pretty printing of the description for USB controllers to
pci_probe_nomatch, so it won't be in the way when loading USB as a module. The reason for them being there in the first place is that every motherboard comes with USB kit and this way it looks more pretty (peter). The real solution will be to define some method of detaching a driver after it has attached.
Diffstat (limited to 'sys/pci')
-rw-r--r--sys/pci/pci.c17
-rw-r--r--sys/pci/pcisupport.c14
2 files changed, 27 insertions, 4 deletions
diff --git a/sys/pci/pci.c b/sys/pci/pci.c
index 4a36158..027a894 100644
--- a/sys/pci/pci.c
+++ b/sys/pci/pci.c
@@ -1164,11 +1164,24 @@ pci_probe_nomatch(device_t dev, device_t child)
{
struct pci_devinfo *dinfo;
pcicfgregs *cfg;
-
+
+ /* a few 'known' devices */
+ if (pci_get_class(dev) == PCIC_SERIALBUS
+ && pci_get_subclass(dev) == PCIS_SERIALBUS_USB) {
+ if (pci_get_progif(dev) == 0x00 /* UHCI */ ) {
+ device_printf(dev, "UHCI USB controller (vendor");
+ } else if (pci_get_progif(dev) == 0x10 /* OHCI */ ) {
+ device_printf(dev, "OHCI USB controller");
+ } else {
+ device_printf(dev, "USB controller");
+ }
+ } else {
+ device_printf(dev, "unknown card");
+ }
dinfo = device_get_ivars(child);
cfg = &dinfo->cfg;
- device_printf(dev, "unknown card (vendor=0x%04x, dev=0x%04x) at %d.%d",
+ printf(" (vendor=0x%04x, dev=0x%04x) at %d.%d",
cfg->vendor,
cfg->device,
pci_get_slot(child),
diff --git a/sys/pci/pcisupport.c b/sys/pci/pcisupport.c
index 32d9ee8..91727f8 100644
--- a/sys/pci/pcisupport.c
+++ b/sys/pci/pcisupport.c
@@ -1034,9 +1034,9 @@ chip_match(device_t dev)
case 0x12378086:
fixwsc_natoma(dev);
return ("Intel 82440FX (Natoma) PCI and memory controller");
+#if 0
case 0x70208086:
return ("Intel 82371SB (PIIX3) USB controller");
-#ifdef NWH
case 0x71128086:
return ("Intel 82371AB/EB (PIIX4) USB controller");
#endif
@@ -1088,8 +1088,10 @@ chip_match(device_t dev)
return ("VIA 82C586B ACPI interface");
case 0x05711106:
return ("VIA 82C586B IDE controller");
+#if 0
case 0x30381106:
return ("VIA 83C572 USB controller");
+#endif
/* AMD -- vendor 0x1022 */
case 0x70061022:
@@ -1106,15 +1108,17 @@ chip_match(device_t dev)
/* id is '10b9" but the register always shows "10b9". -Foxfair */
case 0x154110b9:
return ("AcerLabs M1541 (Aladdin-V) PCI host bridge");
+#if 0
case 0x523710b9:
return ("AcerLabs M5237 (Aladdin-V) USB controller");
+#endif
case 0x710110b9:
return ("AcerLabs M15x3 Power Management Unit");
/* OPTi -- vendor 0x1045 */
case 0xc8221045:
return ("OPTi 82C822 host to PCI Bridge");
-#ifdef NWH
+#if 0
case 0xc8611045:
return ("OPTi 82C861 (FireLink) USB controller");
#endif
@@ -1132,14 +1136,18 @@ chip_match(device_t dev)
case 0x002c1033:
case 0x003b1033:
return NULL;
+#if 0
case 0x00351033:
return ("NEC uPD 9210 USB controller");
+#endif
+#if 0
/* CMD Tech -- vendor 0x1095 */
case 0x06701095:
return ("CMD Tech 670 (USB0670) USB controller");
case 0x06731095:
return ("CMD Tech 673 (USB0673) USB controller");
+#endif
};
if (pci_get_class(dev) == PCIC_BRIDGE
@@ -1148,6 +1156,7 @@ chip_match(device_t dev)
&& pci_get_subclass(dev) != PCIS_BRIDGE_EISA)
return pci_bridge_type(dev);
+#if 0
if (pci_get_class(dev) == PCIC_SERIALBUS
&& pci_get_subclass(dev) == PCIS_SERIALBUS_USB) {
if (pci_get_progif(dev) == 0x00 /* UHCI */ ) {
@@ -1158,6 +1167,7 @@ chip_match(device_t dev)
return ("USB controller");
}
}
+#endif
return NULL;
}
OpenPOWER on IntegriCloud