Patchwork bgmac: add read of interrupt mask after disabling interrupts

login
register
mail settings
Submitter Nathan Hintz
Date Feb. 14, 2013, 5:14 a.m.
Message ID <BLU0-SMTP798071F8F18DD115610285AC0F0@phx.gbl>
Download mbox | patch
Permalink /patch/220352/
State Accepted
Delegated to: David Miller
Headers show

Comments

Nathan Hintz - Feb. 14, 2013, 5:14 a.m.
The specs prescribe an immediate read of the interrupt mask after
disabling interrupts.  This patch updates the driver to match the
specs.

Signed-off-by: Nathan Hintz <nlhintz@hotmail.com>
---
 drivers/net/ethernet/broadcom/bgmac.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
David Miller - Feb. 14, 2013, 6:24 p.m.
From: Nathan Hintz <nlhintz@hotmail.com>
Date: Wed, 13 Feb 2013 21:14:10 -0800

> The specs prescribe an immediate read of the interrupt mask after
> disabling interrupts.  This patch updates the driver to match the
> specs.
> 
> Signed-off-by: Nathan Hintz <nlhintz@hotmail.com>

Applied to net-next.

Please state clearly, in your Subject line, what tree your patch is
targetted at.  In this case "[PATCH net-next] " would have been
an appropriate subject prefix.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Patch

diff --git a/drivers/net/ethernet/broadcom/bgmac.c b/drivers/net/ethernet/broadcom/bgmac.c
index 52d9a54..d341090 100644
--- a/drivers/net/ethernet/broadcom/bgmac.c
+++ b/drivers/net/ethernet/broadcom/bgmac.c
@@ -974,6 +974,7 @@  static void bgmac_chip_intrs_on(struct bgmac *bgmac)
 static void bgmac_chip_intrs_off(struct bgmac *bgmac)
 {
 	bgmac_write(bgmac, BGMAC_INT_MASK, 0);
+	bgmac_read(bgmac, BGMAC_INT_MASK);
 }
 
 /* http://bcm-v4.sipsolutions.net/mac-gbit/gmac/gmac_enable */