]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
myri10ge: Remove nonsensical limit in the tx done routine
authorBrice Goglin <brice@myri.com>
Fri, 13 Jul 2007 18:15:13 +0000 (20:15 +0200)
committerJeff Garzik <jeff@garzik.org>
Mon, 16 Jul 2007 22:28:05 +0000 (18:28 -0400)
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>
drivers/net/myri10ge/myri10ge.c

index e1732c164a4092e925bcf4235b540c60e7ecb92e..deca65330b0f19f2ed085b8c3aeb146db77017f2 100644 (file)
@@ -1060,7 +1060,6 @@ static inline void myri10ge_tx_done(struct myri10ge_priv *mgp, int mcp_index)
        struct myri10ge_tx_buf *tx = &mgp->tx;
        struct sk_buff *skb;
        int idx, len;
-       int limit = 0;
 
        while (tx->pkt_done != mcp_index) {
                idx = tx->done & tx->mask;
@@ -1091,11 +1090,6 @@ static inline void myri10ge_tx_done(struct myri10ge_priv *mgp, int mcp_index)
                                                              bus), len,
                                               PCI_DMA_TODEVICE);
                }
-
-               /* limit potential for livelock by only handling
-                * 2 full tx rings per call */
-               if (unlikely(++limit > 2 * tx->mask))
-                       break;
        }
        /* start the queue if we've stopped it */
        if (netif_queue_stopped(mgp->dev)