]> err.no Git - linux-2.6/commitdiff
ucc_geth: returns NETDEV_TX_BUSY when BD ring is full
authorLi Yang <leoli@freescale.com>
Tue, 6 Mar 2007 08:54:05 +0000 (16:54 +0800)
committerJeff Garzik <jeff@garzik.org>
Tue, 6 Mar 2007 11:10:02 +0000 (06:10 -0500)
Returns NETDEV_TX_BUSY when BD ring is full.

Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
drivers/net/ucc_geth.c

index 639e1e6913bfd573e560613bd0b060bb1146ed4c..dab88b958d6ea9c33c051649077a14e93b8434a9 100644 (file)
@@ -3607,6 +3607,7 @@ static int ucc_geth_start_xmit(struct sk_buff *skb, struct net_device *dev)
        if (bd == ugeth->confBd[txQ]) {
                if (!netif_queue_stopped(dev))
                        netif_stop_queue(dev);
+               return NETDEV_TX_BUSY;
        }
 
        ugeth->txBd[txQ] = bd;
@@ -3622,7 +3623,7 @@ static int ucc_geth_start_xmit(struct sk_buff *skb, struct net_device *dev)
 
        spin_unlock_irq(&ugeth->lock);
 
-       return 0;
+       return NETDEV_TX_OK;
 }
 
 static int ucc_geth_rx(struct ucc_geth_private *ugeth, u8 rxQ, int rx_work_limit)