summaryrefslogtreecommitdiffstats
path: root/usr.sbin/bhyve
diff options
context:
space:
mode:
authorneel <neel@FreeBSD.org>2012-10-27 02:39:08 +0000
committerneel <neel@FreeBSD.org>2012-10-27 02:39:08 +0000
commitbd0ca87b04ee4089d4f0c5b34c5791f80c353d21 (patch)
tree11450b4845653d375a672a805ebbca8cdaefd5d5 /usr.sbin/bhyve
parented9d132c4e9238eb85db69fb4223ddea58b61fed (diff)
downloadFreeBSD-src-bd0ca87b04ee4089d4f0c5b34c5791f80c353d21.zip
FreeBSD-src-bd0ca87b04ee4089d4f0c5b34c5791f80c353d21.tar.gz
Ignore PCI configuration accesses to all bus numbers other than PCI bus 0.
Obtained from: NetApp
Diffstat (limited to 'usr.sbin/bhyve')
-rw-r--r--usr.sbin/bhyve/pci_emul.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/usr.sbin/bhyve/pci_emul.c b/usr.sbin/bhyve/pci_emul.c
index f9d75e3..1836bc9 100644
--- a/usr.sbin/bhyve/pci_emul.c
+++ b/usr.sbin/bhyve/pci_emul.c
@@ -821,7 +821,11 @@ pci_emul_cfgdata(struct vmctx *ctx, int vcpu, int in, int port, int bytes,
assert(bytes == 1 || bytes == 2 || bytes == 4);
- pi = pci_slotinfo[cfgslot][cfgfunc].si_devi;
+ if (cfgbus == 0)
+ pi = pci_slotinfo[cfgslot][cfgfunc].si_devi;
+ else
+ pi = NULL;
+
coff = cfgoff + (port - CONF1_DATA_PORT);
#if 0
OpenPOWER on IntegriCloud