summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/tehuti
diff options
context:
space:
mode:
authorFlorian Westphal <fw@strlen.de>2016-04-24 21:38:13 +0200
committerDavid S. Miller <davem@davemloft.net>2016-04-26 21:53:05 +0200
commita6086a893718db07ef9e7af5624ec27cb376ef0a (patch)
treed79f3678a33c11fa2613cd1f3c4fc393e37222f4 /drivers/net/ethernet/tehuti
parentdrivers: net: use NETDEV_TX_OK instead of NETDEV_TX_LOCKED (diff)
downloadlinux-a6086a893718db07ef9e7af5624ec27cb376ef0a.tar.xz
linux-a6086a893718db07ef9e7af5624ec27cb376ef0a.zip
drivers: net: remove NETDEV_TX_LOCKED
replace the trylock by a full spin_lock and remove TX_LOCKED return value. Followup patch will remove TX_LOCKED from the kernel. Cc: Jon Mason <jdmason@kudzu.us> Cc: Andy Gospodarek <andy@greyhouse.net> Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/tehuti')
-rw-r--r--drivers/net/ethernet/tehuti/tehuti.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/net/ethernet/tehuti/tehuti.c b/drivers/net/ethernet/tehuti/tehuti.c
index 14c9d1baa85c..2524a69db318 100644
--- a/drivers/net/ethernet/tehuti/tehuti.c
+++ b/drivers/net/ethernet/tehuti/tehuti.c
@@ -1610,7 +1610,6 @@ static inline int bdx_tx_space(struct bdx_priv *priv)
* o NETDEV_TX_BUSY Cannot transmit packet, try later
* Usually a bug, means queue start/stop flow control is broken in
* the driver. Note: the driver must NOT put the skb in its DMA ring.
- * o NETDEV_TX_LOCKED Locking failed, please retry quickly.
*/
static netdev_tx_t bdx_tx_transmit(struct sk_buff *skb,
struct net_device *ndev)
@@ -1630,12 +1629,7 @@ static netdev_tx_t bdx_tx_transmit(struct sk_buff *skb,
ENTER;
local_irq_save(flags);
- if (!spin_trylock(&priv->tx_lock)) {
- local_irq_restore(flags);
- DBG("%s[%s]: TX locked, returning NETDEV_TX_LOCKED\n",
- BDX_DRV_NAME, ndev->name);
- return NETDEV_TX_LOCKED;
- }
+ spin_lock(&priv->tx_lock);
/* build tx descriptor */
BDX_ASSERT(f->m.wptr >= f->m.memsz); /* started with valid wptr */