From ad3d2a4dc52cf31fb1a45644d487eaffef8278ec Mon Sep 17 00:00:00 2001 From: "Justin T. Gibbs" Date: Thu, 22 Sep 2005 05:11:35 +0000 Subject: Use the AHC_DISABLE_PCI_PERR flag to silence parity error reporting on chips where setting the FAILDIS bit is not effective. While here, try again to make it clear that reported parity errors indicate a failure of some PCI device *other than* the aic7xxx controller. --- sys/dev/aic7xxx/aic7xxx_pci.c | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) (limited to 'sys/dev/aic7xxx') diff --git a/sys/dev/aic7xxx/aic7xxx_pci.c b/sys/dev/aic7xxx/aic7xxx_pci.c index d37607daadd5..25c24ea5ea46 100644 --- a/sys/dev/aic7xxx/aic7xxx_pci.c +++ b/sys/dev/aic7xxx/aic7xxx_pci.c @@ -2023,11 +2023,15 @@ ahc_pci_intr(struct ahc_softc *ahc) status1 = aic_pci_read_config(ahc->dev_softc, PCIR_STATUS + 1, /*bytes*/1); - printf("%s: PCI error Interrupt at seqaddr = 0x%x\n", - ahc_name(ahc), - ahc_inb(ahc, SEQADDR0) | (ahc_inb(ahc, SEQADDR1) << 8)); + if ((status1 & ~DPE) != 0 + || (ahc->flags & AHC_DISABLE_PCI_PERR) == 0) { + printf("%s: PCI error Interrupt at seqaddr = 0x%x\n", + ahc_name(ahc), + ahc_inb(ahc, SEQADDR0) | (ahc_inb(ahc, SEQADDR1) << 8)); + } - if (status1 & DPE) { + if (status1 & DPE + && (ahc->flags & AHC_DISABLE_PCI_PERR) == 0) { ahc->pci_target_perr_count++; printf("%s: Data Parity Error Detected during address " "or write data phase\n", ahc_name(ahc)); @@ -2060,17 +2064,20 @@ ahc_pci_intr(struct ahc_softc *ahc) ahc_outb(ahc, CLRINT, CLRPARERR); } - if (ahc->pci_target_perr_count > AHC_PCI_TARGET_PERR_THRESH) { + if (ahc->pci_target_perr_count > AHC_PCI_TARGET_PERR_THRESH + && (ahc->flags & AHC_DISABLE_PCI_PERR) == 0) { printf( "%s: WARNING WARNING WARNING WARNING\n" "%s: Too many PCI parity errors observed as a target.\n" -"%s: Some device on this bus is generating bad parity.\n" -"%s: This is an error *observed by*, not *generated by*, this controller.\n" +"%s: Some device on this PCI bus is generating bad parity.\n" +"%s: This is an error *observed by*, not *generated by*, %s.\n" "%s: PCI parity error checking has been disabled.\n" "%s: WARNING WARNING WARNING WARNING\n", ahc_name(ahc), ahc_name(ahc), ahc_name(ahc), - ahc_name(ahc), ahc_name(ahc), ahc_name(ahc)); + ahc_name(ahc), ahc_name(ahc), ahc_name(ahc), + ahc_name(ahc)); ahc->seqctl |= FAILDIS; + ahc->flags |= AHC_DISABLE_PCI_PERR; ahc_outb(ahc, SEQCTL, ahc->seqctl); } ahc_unpause(ahc); -- cgit v1.2.3