virtio_net: be drop monitor friendly
authorEric Dumazet <edumazet@google.com>
Thu, 24 Aug 2017 16:02:49 +0000 (09:02 -0700)
committerDavid S. Miller <davem@davemloft.net>
Thu, 24 Aug 2017 18:50:21 +0000 (11:50 -0700)
This change is needed to not fool drop monitor.
(perf record ... -e skb:kfree_skb )

Packets were properly sent and are consumed after TX completion.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/virtio_net.c

index 98f17b05c68b745276ecbe67d2934918eaf340bd..b06169ea60dc9d519f9a7673e9aea809539dbd5c 100644 (file)
@@ -1058,7 +1058,7 @@ static void free_old_xmit_skbs(struct send_queue *sq)
                bytes += skb->len;
                packets++;
 
-               dev_kfree_skb_any(skb);
+               dev_consume_skb_any(skb);
        }
 
        /* Avoid overhead when no packets have been processed