summaryrefslogtreecommitdiffstats
path: root/sys/pci/pcisupport.c
diff options
context:
space:
mode:
authorse <se@FreeBSD.org>1996-09-02 21:23:06 +0000
committerse <se@FreeBSD.org>1996-09-02 21:23:06 +0000
commitd6fd1776b01fc9ff83bdc615bdc9cc7cba18861b (patch)
treeb0f732ebdc89b979374c99d62c9f54989ec6af25 /sys/pci/pcisupport.c
parenta74ea45a26f38149f5e54d1f975524fbce7ab15b (diff)
downloadFreeBSD-src-d6fd1776b01fc9ff83bdc615bdc9cc7cba18861b.zip
FreeBSD-src-d6fd1776b01fc9ff83bdc615bdc9cc7cba18861b.tar.gz
Add preliminary support for the Orion PCI chip set. It is special in the
way it attaches multiple PCI buses directly to the CPU, instead of having them hanging off from PCI to PCI bridges. This code is a hack, and will be obsoleted by the planned rework of the PCI code, which will change the dealing with PCI to PCI bridges and other special devices significantly. The patch also adds a kern_devconf entry for PCI bus 0 which is assumed to be a child of cpu0. The new PCI code will make it possible to hand out the kern_devconf structure to a pci device being attached, since this is (regretably, IMHO) required by a few ISA devices. Finally there are new PCI ids for some Intel chip set devices, which had already been known to 2.1.5R, but did not make it into -current. This closes "kern/1558: PCI probe seems to have lost a device in -current".
Diffstat (limited to 'sys/pci/pcisupport.c')
-rw-r--r--sys/pci/pcisupport.c56
1 files changed, 53 insertions, 3 deletions
diff --git a/sys/pci/pcisupport.c b/sys/pci/pcisupport.c
index 713ea03..ea57e08 100644
--- a/sys/pci/pcisupport.c
+++ b/sys/pci/pcisupport.c
@@ -1,6 +1,6 @@
/**************************************************************************
**
-** $Id: pcisupport.c,v 1.32 1996/02/17 23:57:04 se Exp $
+** $Id: pcisupport.c,v 1.33 1996/04/07 17:32:36 bde Exp $
**
** Device driver for DEC/INTEL PCI chipsets.
**
@@ -51,6 +51,8 @@
#include <pci/pcivar.h>
#include <pci/pcireg.h>
+static void config_orion (pcici_t tag);
+
/*---------------------------------------------------------
**
** Intel chipsets for 486 / Pentium processor
@@ -128,9 +130,21 @@ chipset_probe (pcici_t tag, pcidi_t type)
return ("Intel 82434NX (Neptune) PCI cache memory controller");
return ("Intel 82434LX (Mercury) PCI cache memory controller");
case 0x122d8086:
- return ("Intel 82437 (Triton) PCI cache memory controller");
+ return ("Intel 82437FX PCI cache memory controller");
case 0x122e8086:
- return ("Intel 82371 (Triton) PCI-ISA bridge");
+ return ("Intel 82371FB PCI-ISA bridge");
+ case 0x12308086:
+ return ("Intel 82371FB IDE interface");
+ case 0x70008086:
+ return ("Intel 82371SB PCI-ISA bridge");
+ case 0x70108086:
+ return ("Intel 82371SB IDE interface");
+ case 0x12378086:
+ return ("Intel 82440FX (Natoma) PCI and memory controller");
+ case 0x84c48086:
+ return ("Intel 82450KX (Orion) PCI memory controller");
+ case 0x84c58086:
+ return ("Intel 8245??? (Orion) host to PCI bridge");
case 0x04961039:
return ("SiS 85c496");
case 0x04061039:
@@ -581,6 +595,21 @@ writeconfig (pcici_t config_id, const struct condmsg *tbl)
}
}
+#ifdef DUMPCONFIGSPACE
+static void
+dumpconfigspace (pcici_t tag)
+{
+ int reg;
+ printf ("configuration space registers:");
+ for (reg = 0; reg < 0x100; reg+=4) {
+ if ((reg & 0x0f) == 0)
+ printf ("\n%02x:\t", reg);
+ printf ("%08x ", pci_conf_read (tag, reg));
+ }
+ printf ("\n");
+}
+#endif /* DUMPCONFIGSPACE */
+
#endif /* PCI_QUIET */
static void
@@ -616,6 +645,9 @@ chipset_attach (pcici_t config_id, int unit)
case 0x122e8086:
writeconfig (config_id, conf82371fb);
break;
+ case 0x84c48086: /* Intel Orion */
+ config_orion (config_id);
+ break;
#if 0
case 0x00011011: /* DEC 21050 */
case 0x00221014: /* IBM xxx */
@@ -762,3 +794,21 @@ ign_probe (pcici_t tag, pcidi_t type)
static void
ign_attach (pcici_t tag, int unit)
{}
+
+/*---------------------------------------------------------
+**
+** special PCI chip set devices
+**
+**---------------------------------------------------------
+*/
+
+extern unsigned pciroots;
+
+static void
+config_orion (pcici_t tag)
+{
+ if (pci_conf_read (tag, 0x4A) > 0) {
+ pciroots++;
+ }
+}
+
OpenPOWER on IntegriCloud