diff options
author | gibbs <gibbs@FreeBSD.org> | 1998-10-07 03:40:51 +0000 |
---|---|---|
committer | gibbs <gibbs@FreeBSD.org> | 1998-10-07 03:40:51 +0000 |
commit | c3bd7bdfdda594530f77207803fdcfba4862f4bf (patch) | |
tree | dd49b1925ac07eb5b7638f177abb393d7d158439 /sys/pci | |
parent | 04f5e2e068d6ab729527b802a57364c9f7dea8e6 (diff) | |
download | FreeBSD-src-c3bd7bdfdda594530f77207803fdcfba4862f4bf.zip FreeBSD-src-c3bd7bdfdda594530f77207803fdcfba4862f4bf.tar.gz |
ahc_pci.c:
Disable DPARCKEN in the DSCOMMAND0 register on the aic7890/91/96/97.
Parity checking is broken for some chip/MB combinations and this
is the work around recommended by Adaptec.
dpt_pci.c:
Remove a superflous '{' that prevented DPT_ALLOW_MEMIO from working.
pcireg.h:
Add a definition for Parity Error Reponse bit in the PCI Space
command register.
Diffstat (limited to 'sys/pci')
-rw-r--r-- | sys/pci/ahc_pci.c | 18 | ||||
-rw-r--r-- | sys/pci/dpt_pci.c | 4 | ||||
-rw-r--r-- | sys/pci/pcireg.h | 3 |
3 files changed, 17 insertions, 8 deletions
diff --git a/sys/pci/ahc_pci.c b/sys/pci/ahc_pci.c index 50d8efc..344658d 100644 --- a/sys/pci/ahc_pci.c +++ b/sys/pci/ahc_pci.c @@ -34,7 +34,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id$ + * $Id: ahc_pci.c,v 1.1 1998/09/15 07:25:33 gibbs Exp $ */ #include <pci.h> @@ -510,10 +510,14 @@ ahc_pci_attach(pcici_t config_id, int unit) { u_int dscommand0; + /* + * DPARCKEN doesn't work correctly on + * some MBs so don't use it. + */ id_string = "aic7896/97 "; dscommand0 = ahc_inb(ahc, DSCOMMAND0); - dscommand0 &= ~USCBSIZE32; - dscommand0 |= CACHETHEN|DPARCKEN|MPARCKEN; + dscommand0 &= ~(USCBSIZE32|DPARCKEN); + dscommand0 |= CACHETHEN|MPARCKEN; ahc_outb(ahc, DSCOMMAND0, dscommand0); break; } @@ -521,10 +525,14 @@ ahc_pci_attach(pcici_t config_id, int unit) { u_int dscommand0; + /* + * DPARCKEN doesn't work correctly on + * some MBs so don't use it. + */ id_string = "aic7890/91 "; dscommand0 = ahc_inb(ahc, DSCOMMAND0); - dscommand0 &= ~USCBSIZE32; - dscommand0 |= CACHETHEN|DPARCKEN|MPARCKEN; + dscommand0 &= ~(USCBSIZE32|DPARCKEN); + dscommand0 |= CACHETHEN|MPARCKEN; ahc_outb(ahc, DSCOMMAND0, dscommand0); break; } diff --git a/sys/pci/dpt_pci.c b/sys/pci/dpt_pci.c index 2e2e16b..7af9a2a 100644 --- a/sys/pci/dpt_pci.c +++ b/sys/pci/dpt_pci.c @@ -32,7 +32,7 @@ * dptpci.c: PCI Bus Attachment for DPT SCSI HBAs */ -#ident "$Id: dpt_pci.c,v 1.7 1998/08/05 00:54:37 eivind Exp $" +#ident "$Id: dpt_pci.c,v 1.8 1998/09/15 08:33:38 gibbs Exp $" #include "opt_devfs.h" #include "opt_dpt.h" @@ -126,7 +126,7 @@ dpt_pci_attach(pcici_t config_id, int unit) command = pci_conf_read(config_id, PCI_COMMAND_STATUS_REG); #ifdef DPT_ALLOW_MEMIO if ((command & PCI_COMMAND_MEM_ENABLE) == 0 - || (pci_map_mem(config_id, PCI_BASEADR1, &vaddr, &paddr)) == 0) { + || (pci_map_mem(config_id, PCI_BASEADR1, &vaddr, &paddr)) == 0) #endif if ((command & PCI_COMMAND_IO_ENABLE) == 0 || (pci_map_port(config_id, PCI_BASEADR0, &io_base)) == 0) diff --git a/sys/pci/pcireg.h b/sys/pci/pcireg.h index 9e8c85e..0adb540 100644 --- a/sys/pci/pcireg.h +++ b/sys/pci/pcireg.h @@ -26,7 +26,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: pcireg.h,v 1.18 1997/06/01 16:00:43 peter Exp $ + * $Id: pcireg.h,v 1.19 1997/09/20 07:41:58 dyson Exp $ * */ @@ -56,6 +56,7 @@ #define PCIM_CMD_PORTEN 0x0001 #define PCIM_CMD_MEMEN 0x0002 #define PCIM_CMD_BUSMASTEREN 0x0004 +#define PCIM_CMD_PERRESPEN 0x0040 #define PCIR_STATUS 0x06 #define PCIR_REVID 0x08 #define PCIR_PROGIF 0x09 |