aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
authorBrice Goglin <brice@myri.com>2007-07-13 14:15:13 -0400
committerJeff Garzik <jeff@garzik.org>2007-07-16 18:28:05 -0400
commitc97884b5de95a11d1668f134a51c1d150d214391 (patch)
treeb350e1e1ec743f8c5cb95ec0086b7b72cf032d48 /drivers/net
parentbe5ae973197b84e9f39784b73d08ba41931fbdc9 (diff)
myri10ge: Remove nonsensical limit in the tx done routine
Remove nonsensical limit in the tx done routine. Specifically, the loop will always terminate after processing <= 1 rings worth of frames, as the mcp index is not refetched, so the removed conditional could never be true. Signed-off-by: Brice Goglin <brice@myri.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/myri10ge/myri10ge.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/drivers/net/myri10ge/myri10ge.c b/drivers/net/myri10ge/myri10ge.c
index e1732c164a40..deca65330b0f 100644
--- a/drivers/net/myri10ge/myri10ge.c
+++ b/drivers/net/myri10ge/myri10ge.c
@@ -1060,7 +1060,6 @@ static inline void myri10ge_tx_done(struct myri10ge_priv *mgp, int mcp_index)
1060 struct myri10ge_tx_buf *tx = &mgp->tx; 1060 struct myri10ge_tx_buf *tx = &mgp->tx;
1061 struct sk_buff *skb; 1061 struct sk_buff *skb;
1062 int idx, len; 1062 int idx, len;
1063 int limit = 0;
1064 1063
1065 while (tx->pkt_done != mcp_index) { 1064 while (tx->pkt_done != mcp_index) {
1066 idx = tx->done & tx->mask; 1065 idx = tx->done & tx->mask;
@@ -1091,11 +1090,6 @@ static inline void myri10ge_tx_done(struct myri10ge_priv *mgp, int mcp_index)
1091 bus), len, 1090 bus), len,
1092 PCI_DMA_TODEVICE); 1091 PCI_DMA_TODEVICE);
1093 } 1092 }
1094
1095 /* limit potential for livelock by only handling
1096 * 2 full tx rings per call */
1097 if (unlikely(++limit > 2 * tx->mask))
1098 break;
1099 } 1093 }
1100 /* start the queue if we've stopped it */ 1094 /* start the queue if we've stopped it */
1101 if (netif_queue_stopped(mgp->dev) 1095 if (netif_queue_stopped(mgp->dev)