From d92a56e529c197bb5ba563d69cd3899bf064f19e Mon Sep 17 00:00:00 2001 From: Xin LI Date: Fri, 5 Dec 2008 21:32:30 +0000 Subject: MFC r185593: Don't attempt to clear status updates if we did not do a link state change. As a side effect, this makes the excessive interrupts to disappear which has been observed as a regression in recent stable/7. Reported by: many (on -stable@) Reviewed by: davidch Approved by: re (kensmith, kib) --- sys/dev/bce/if_bce.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'sys/dev') diff --git a/sys/dev/bce/if_bce.c b/sys/dev/bce/if_bce.c index 9b40698861c1..e31bdd63049e 100644 --- a/sys/dev/bce/if_bce.c +++ b/sys/dev/bce/if_bce.c @@ -7030,13 +7030,14 @@ bce_intr(void *xsc) /* Was it a link change interrupt? */ if ((status_attn_bits & STATUS_ATTN_BITS_LINK_STATE) != - (sc->status_block->status_attn_bits_ack & STATUS_ATTN_BITS_LINK_STATE)) + (sc->status_block->status_attn_bits_ack & STATUS_ATTN_BITS_LINK_STATE)) { bce_phy_intr(sc); - /* Clear any transient status updates during link state change. */ - REG_WR(sc, BCE_HC_COMMAND, - sc->hc_command | BCE_HC_COMMAND_COAL_NOW_WO_INT); - REG_RD(sc, BCE_HC_COMMAND); + /* Clear any transient status updates during link state change. */ + REG_WR(sc, BCE_HC_COMMAND, + sc->hc_command | BCE_HC_COMMAND_COAL_NOW_WO_INT); + REG_RD(sc, BCE_HC_COMMAND); + } /* If any other attention is asserted then the chip is toast. */ if (((status_attn_bits & ~STATUS_ATTN_BITS_LINK_STATE) != -- cgit v1.3