summaryrefslogtreecommitdiff
path: root/sys/arch/amd64/pci
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2011-01-10 16:26:28 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2011-01-10 16:26:28 +0000
commitd5752f9442ad624ff1a77a80568f89b94a24b927 (patch)
treee1b0b3370393af97c29b9418cc18f6e77014d016 /sys/arch/amd64/pci
parent0a4a9df88e4339b22efeef2192b29449d870ee36 (diff)
Only use MMCFG extended PCIe config space. Gets us back the on-CPU PCI devices on AMD Family 0Fh processors.
Diffstat (limited to 'sys/arch/amd64/pci')
-rw-r--r--sys/arch/amd64/pci/pci_machdep.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/arch/amd64/pci/pci_machdep.c b/sys/arch/amd64/pci/pci_machdep.c
index 4e7a6d9f0a5..f36c3cdc82f 100644
--- a/sys/arch/amd64/pci/pci_machdep.c
+++ b/sys/arch/amd64/pci/pci_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pci_machdep.c,v 1.39 2011/01/09 11:38:10 kettenis Exp $ */
+/* $OpenBSD: pci_machdep.c,v 1.40 2011/01/10 16:26:27 kettenis Exp $ */
/* $NetBSD: pci_machdep.c,v 1.3 2003/05/07 21:33:58 fvdl Exp $ */
/*-
@@ -217,7 +217,7 @@ pci_conf_read(pci_chipset_tag_t pc, pcitag_t tag, int reg)
pcireg_t data;
int bus;
- if (pci_mcfg_addr) {
+ if (pci_mcfg_addr && reg >= PCI_CONFIG_SPACE_SIZE) {
pci_decompose_tag(pc, tag, &bus, NULL, NULL);
if (bus >= pci_mcfg_min_bus && bus <= pci_mcfg_max_bus) {
pci_mcfg_map_bus(bus);
@@ -241,7 +241,7 @@ pci_conf_write(pci_chipset_tag_t pc, pcitag_t tag, int reg, pcireg_t data)
{
int bus;
- if (pci_mcfg_addr) {
+ if (pci_mcfg_addr && reg >= PCI_CONFIG_SPACE_SIZE) {
pci_decompose_tag(pc, tag, &bus, NULL, NULL);
if (bus >= pci_mcfg_min_bus && bus <= pci_mcfg_max_bus) {
pci_mcfg_map_bus(bus);