]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
virtio: net: make it clear that virtqueue_add_buf() no longer returns > 0
authorRusty Russell <rusty@rustcorp.com.au>
Tue, 16 Oct 2012 13:26:15 +0000 (23:56 +1030)
committerRusty Russell <rusty@rustcorp.com.au>
Tue, 18 Dec 2012 04:50:36 +0000 (15:20 +1030)
We simplified virtqueue_add_buf(), make it clear in the callers.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
drivers/net/virtio_net.c

index 7c7f5a94ca4fc48fc9a41571f6760caf84a1c0c4..62898910708a6ed7451cbbb81e9874f83cd87c8c 100644 (file)
@@ -635,7 +635,7 @@ static netdev_tx_t start_xmit(struct sk_buff *skb, struct net_device *dev)
        err = xmit_skb(vi, skb);
 
        /* This should not happen! */
-       if (unlikely(err < 0)) {
+       if (unlikely(err)) {
                dev->stats.tx_fifo_errors++;
                if (net_ratelimit())
                        dev_warn(&dev->dev,