Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e782410e authored by Heiner Kallweit's avatar Heiner Kallweit Committed by David S. Miller
Browse files

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: default avatarHeiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent b09026c6
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -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)) {