]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit
qed: Fix interrupt flags on Rx LL2
authorRam Amrani <Ram.Amrani@cavium.com>
Tue, 14 Mar 2017 13:26:02 +0000 (15:26 +0200)
committerDavid S. Miller <davem@davemloft.net>
Tue, 14 Mar 2017 18:37:05 +0000 (11:37 -0700)
commit1df2adedcce17ad4a39fba74f0e2b611f797fe10
treece0c1a0efe4b0c112eb06e4d1049710d1e0aa929
parent4621ceb279d065151eb940ce8a4728b10c0646c7
qed: Fix interrupt flags on Rx LL2

Before iterating over the the LL2 Rx ring, the ring's
spinlock is taken via spin_lock_irqsave().
The actual processing of the packet [including handling
by the protocol driver] is done without said lock,
so qed releases the spinlock and re-claims it afterwards.

Problem is that the final spin_lock_irqrestore() at the end
of the iteration uses the original flags saved from the
initial irqsave() instead of the flags from the most recent
irqsave(). So it's possible that the interrupt status would
be incorrect at the end of the processing.

Fixes: 0a7fb11c23c0 ("qed: Add Light L2 support");
CC: Ram Amrani <Ram.Amrani@cavium.com>
Signed-off-by: Yuval Mintz <Yuval.Mintz@cavium.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qed/qed_ll2.c