diff options
author | wpaul <wpaul@FreeBSD.org> | 2005-10-25 04:53:29 +0000 |
---|---|---|
committer | wpaul <wpaul@FreeBSD.org> | 2005-10-25 04:53:29 +0000 |
commit | a413021644c3f113e369c21f1ea70ca08abea47c (patch) | |
tree | 099921b5f5655390e53e58305e60fc44801a732d /sys/i386/pci | |
parent | 2feaf16457936843df04a87b82c3c9913a482a51 (diff) | |
download | FreeBSD-src-a413021644c3f113e369c21f1ea70ca08abea47c.zip FreeBSD-src-a413021644c3f113e369c21f1ea70ca08abea47c.tar.gz |
Modify the pci_cfgdisable() routine to bring it more in line with
other OSes (Solaris, Linux, VxWorks). It's not necessary to write a 0
to the config address register when using config mechanism 1 to turn
off config access. In fact, it can be downright troublesome, since it
seems to confuse the PCI-PCI bridge in the AMD8111 chipset and cause
it to sporadically botch reads from some devices. This is the cause
of the missing USP ports problem I was experiencing with my Sun Opteron
system.
Also correct the case for mechanism 2: it's only necessary to write
a 0 to the ENABLE port.
Diffstat (limited to 'sys/i386/pci')
-rw-r--r-- | sys/i386/pci/pci_cfgreg.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/sys/i386/pci/pci_cfgreg.c b/sys/i386/pci/pci_cfgreg.c index adea6dc..37003a7 100644 --- a/sys/i386/pci/pci_cfgreg.c +++ b/sys/i386/pci/pci_cfgreg.c @@ -237,11 +237,15 @@ pci_cfgdisable(void) { switch (cfgmech) { case CFGMECH_1: - outl(CONF1_ADDR_PORT, 0); - break; + /* + * Do nothing for the config mechanism 1 case. + * Writing a 0 to the address port can apparently + * confuse some bridges and cause spurious + * access failures. + */ + break; case CFGMECH_2: outb(CONF2_ENABLE_PORT, 0); - outb(CONF2_FORWARD_PORT, 0); break; } } |