diff options
author | Bryan O'Sullivan <bos@pathscale.com> | 2006-09-28 12:00:18 -0400 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2006-09-28 14:17:03 -0400 |
commit | 89d1e09b6a6d844ef327937f41658a426be42501 (patch) | |
tree | 5730241c737baf67b0b1ddf89ff38f6936d649c4 /drivers/infiniband/hw/ipath/ipath_iba6110.c | |
parent | 510847750c9d26052a71631e0fcad9e7f7a5f369 (diff) |
IB/ipath: Fix and recover TXE piobuf and PBC parity errors
We can sometimes trigger parity errors due to processor speculative
reads to our write-combined memory (mostly seen on Woodcrest). Add a
stats counter for these.
Factored out the sendbuffererror buffer cancellation code so it can be
used in the new handling; suppress likely subsequent error messages if
within two jiffies of the cancellation.
Also restore 2 dropped TXE lines on hwe_bitsextant noticed while
debugging.
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers/infiniband/hw/ipath/ipath_iba6110.c')
-rw-r--r-- | drivers/infiniband/hw/ipath/ipath_iba6110.c | 32 |
1 files changed, 31 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/ipath/ipath_iba6110.c b/drivers/infiniband/hw/ipath/ipath_iba6110.c index fd49c9c32c68..9e4e8d4c6e20 100644 --- a/drivers/infiniband/hw/ipath/ipath_iba6110.c +++ b/drivers/infiniband/hw/ipath/ipath_iba6110.c | |||
@@ -451,7 +451,10 @@ static void ipath_ht_handle_hwerrors(struct ipath_devdata *dd, char *msg, | |||
451 | * make sure we get this much out, unless told to be quiet, | 451 | * make sure we get this much out, unless told to be quiet, |
452 | * or it's occurred within the last 5 seconds | 452 | * or it's occurred within the last 5 seconds |
453 | */ | 453 | */ |
454 | if ((hwerrs & ~dd->ipath_lasthwerror) || | 454 | if ((hwerrs & ~(dd->ipath_lasthwerror | |
455 | ((INFINIPATH_HWE_TXEMEMPARITYERR_PIOBUF | | ||
456 | INFINIPATH_HWE_TXEMEMPARITYERR_PIOPBC) | ||
457 | << INFINIPATH_HWE_TXEMEMPARITYERR_SHIFT))) || | ||
455 | (ipath_debug & __IPATH_VERBDBG)) | 458 | (ipath_debug & __IPATH_VERBDBG)) |
456 | dev_info(&dd->pcidev->dev, "Hardware error: hwerr=0x%llx " | 459 | dev_info(&dd->pcidev->dev, "Hardware error: hwerr=0x%llx " |
457 | "(cleared)\n", (unsigned long long) hwerrs); | 460 | "(cleared)\n", (unsigned long long) hwerrs); |
@@ -464,6 +467,33 @@ static void ipath_ht_handle_hwerrors(struct ipath_devdata *dd, char *msg, | |||
464 | 467 | ||
465 | ctrl = ipath_read_kreg32(dd, dd->ipath_kregs->kr_control); | 468 | ctrl = ipath_read_kreg32(dd, dd->ipath_kregs->kr_control); |
466 | if (ctrl & INFINIPATH_C_FREEZEMODE) { | 469 | if (ctrl & INFINIPATH_C_FREEZEMODE) { |
470 | /* | ||
471 | * parity errors in send memory are recoverable, | ||
472 | * just cancel the send (if indicated in * sendbuffererror), | ||
473 | * count the occurrence, unfreeze (if no other handled | ||
474 | * hardware error bits are set), and continue. They can | ||
475 | * occur if a processor speculative read is done to the PIO | ||
476 | * buffer while we are sending a packet, for example. | ||
477 | */ | ||
478 | if (hwerrs & ((INFINIPATH_HWE_TXEMEMPARITYERR_PIOBUF | | ||
479 | INFINIPATH_HWE_TXEMEMPARITYERR_PIOPBC) | ||
480 | << INFINIPATH_HWE_TXEMEMPARITYERR_SHIFT)) { | ||
481 | ipath_stats.sps_txeparity++; | ||
482 | ipath_dbg("Recovering from TXE parity error (%llu), " | ||
483 | "hwerrstatus=%llx\n", | ||
484 | (unsigned long long) ipath_stats.sps_txeparity, | ||
485 | (unsigned long long) hwerrs); | ||
486 | ipath_disarm_senderrbufs(dd); | ||
487 | hwerrs &= ~((INFINIPATH_HWE_TXEMEMPARITYERR_PIOBUF | | ||
488 | INFINIPATH_HWE_TXEMEMPARITYERR_PIOPBC) | ||
489 | << INFINIPATH_HWE_TXEMEMPARITYERR_SHIFT); | ||
490 | if (!hwerrs) { /* else leave in freeze mode */ | ||
491 | ipath_write_kreg(dd, | ||
492 | dd->ipath_kregs->kr_control, | ||
493 | dd->ipath_control); | ||
494 | return; | ||
495 | } | ||
496 | } | ||
467 | if (hwerrs) { | 497 | if (hwerrs) { |
468 | /* | 498 | /* |
469 | * if any set that we aren't ignoring; only | 499 | * if any set that we aren't ignoring; only |