summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys/dev/pci/pci.c2
-rw-r--r--sys/dev/pci/pcireg.h10
2 files changed, 2 insertions, 10 deletions
diff --git a/sys/dev/pci/pci.c b/sys/dev/pci/pci.c
index e8e8245..0c7486e 100644
--- a/sys/dev/pci/pci.c
+++ b/sys/dev/pci/pci.c
@@ -835,7 +835,7 @@ pci_add_children(device_t dev, int busno, size_t dinfo_size)
pcifunchigh = 0;
f = 0;
hdrtype = REG(PCIR_HEADERTYPE, 1);
- if ((hdrtype & ~PCIM_MFDEV) > 2)
+ if ((hdrtype & ~PCIM_MFDEV) > PCI_MAXHDRTYPE)
continue;
if (hdrtype & PCIM_MFDEV)
pcifunchigh = PCI_FUNCMAX;
diff --git a/sys/dev/pci/pcireg.h b/sys/dev/pci/pcireg.h
index 049f391..6e5e1d9 100644
--- a/sys/dev/pci/pcireg.h
+++ b/sys/dev/pci/pcireg.h
@@ -43,6 +43,7 @@
#define PCI_SLOTMAX 31
#define PCI_FUNCMAX 7
#define PCI_REGMAX 255
+#define PCI_MAXHDRTYPE 2
/* PCI config header registers for all devices */
@@ -311,12 +312,3 @@
#define PCIXM_STATUS_MAXSPLITS 0x0380 /* Maximum Split Transactions */
#define PCIXM_STATUS_MAXCRDS 0x1C00 /* Maximum Cumulative Read Size */
#define PCIXM_STATUS_RCVDSCEM 0x2000 /* Received a Split Comp w/Error msg */
-
-#if 0
-/* some PCI vendor definitions (only used to identify ancient devices !!! */
-
-#define PCIV_INTEL 0x8086
-
-#define PCID_INTEL_SATURN 0x0483
-#define PCID_INTEL_ORION 0x84c4
-#endif
OpenPOWER on IntegriCloud