atl1: use spin_trylock_irqsave()
Subsystems (2)
PATCH 1/1 atl1: use spin_trylock_irqsave()
From: Ingo Molnar <[email protected]>
use the simpler spin_trylock_irqsave() API to get the adapter lock.
[ this is also a fix for -rt where adapter->lock is a sleeping lock. ]
Signed-off-by Ingo Molnar <[email protected]>
Signed-off-by Jay Cliburn <[email protected]>
--- drivers/net/atl1/atl1_main.c | 4 +--- 1 files changed, 1 insertions(+), 3 deletions(-)
drivers/net/atl1/atl1_main.c +1 -3
@@ -1704,10 +1704,8 @@ static int atl1_xmit_frame(struct sk_buff *skb, struct net_device *netdev) } } -local_irq_save (flags); -if (!spin_trylock (&adapter->lock)) { +if (!spin_trylock_irqsave (&adapter->lock, flags)) {/* Can't get lock - tell upper layer to requeue */ -local_irq_restore (flags);dev_printk (KERN_DEBUG , &adapter->pdev->dev,"tx locked\n" );return NETDEV_TX_LOCKED ; }
Signature · 1 line
1.5.2.2
Jeff Garzik
AppliedQuoted 11 lines · Jay Cliburn
From: Ingo Molnar <[email protected]>
use the simpler
spin_trylock_irqsave()API to get the adapter lock.[ this is also a fix for -rt where
adapter->lockis a sleeping lock. ]Signed-off-by Ingo Molnar <[email protected]>Signed-off-by Jay Cliburn <[email protected]>--- drivers/net/atl1/atl1_main.c | 4 +--- 1 files changed, 1 insertions(+), 3 deletions(-)
applied to #upstream-fixes