diff options
author | Heiner Kallweit <hkallweit1@gmail.com> | 2018-12-15 16:25:05 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-12-15 11:22:48 -0800 |
commit | e782410ed2378a2ddac58d944c3cf0c6f96b1ff3 (patch) | |
tree | 73ee6b49f18431a534333f324f792048c7682e53 /drivers/net/ethernet/realtek | |
parent | b09026c6913eeef1b21914a9d441ba275df40f27 (diff) |
r8169: improve spurious interrupt detection
Improve detection of spurious interrupts by checking against the
interrupt mask as currently set in the chip.
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/realtek')
-rw-r--r-- | drivers/net/ethernet/realtek/r8169.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/ethernet/realtek/r8169.c b/drivers/net/ethernet/realtek/r8169.c index e26c48bd54a2..18e39e5e447b 100644 --- a/drivers/net/ethernet/realtek/r8169.c +++ b/drivers/net/ethernet/realtek/r8169.c @@ -6405,8 +6405,9 @@ static irqreturn_t rtl8169_interrupt(int irq, void *dev_instance) { struct rtl8169_private *tp = dev_instance; u16 status = rtl_get_events(tp); + u16 irq_mask = RTL_R16(tp, IntrMask); - if (status == 0xffff || !(status & tp->irq_mask)) + if (status == 0xffff || !(status & irq_mask)) return IRQ_NONE; if (unlikely(status & SYSErr)) { |