summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/oki-semi
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2009-06-20 09:36:54 (GMT)
committerScott Wood <scottwood@freescale.com>2014-04-10 00:18:55 (GMT)
commit5001984143b8eab3715681063220aa6f57d9ebb0 (patch)
tree2ed9c7ef93b2fc096a4781b34315e16c9731890d /drivers/net/ethernet/oki-semi
parente560bacfa970cf282e62596bebaaf4d50a76714c (diff)
downloadlinux-fsl-qoriq-5001984143b8eab3715681063220aa6f57d9ebb0.tar.xz
drivers/net: fix livelock issues
Preempt-RT runs into a live lock issue with the NETDEV_TX_LOCKED micro optimization. The reason is that the softirq thread is rescheduling itself on that return value. Depending on priorities it starts to monoplize the CPU and livelock on UP systems. Remove it. Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'drivers/net/ethernet/oki-semi')
-rw-r--r--drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c b/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c
index 5a0f04c..e732812 100644
--- a/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c
+++ b/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c
@@ -2148,10 +2148,8 @@ static int pch_gbe_xmit_frame(struct sk_buff *skb, struct net_device *netdev)
struct pch_gbe_tx_ring *tx_ring = adapter->tx_ring;
unsigned long flags;
- if (!spin_trylock_irqsave(&tx_ring->tx_lock, flags)) {
- /* Collision - tell upper layer to requeue */
- return NETDEV_TX_LOCKED;
- }
+ spin_lock_irqsave(&tx_ring->tx_lock, flags);
+
if (unlikely(!PCH_GBE_DESC_UNUSED(tx_ring))) {
netif_stop_queue(netdev);
spin_unlock_irqrestore(&tx_ring->tx_lock, flags);