Skip to content

Commit

Permalink
VIRTIO: Use __skb_queue_purge()
Browse files Browse the repository at this point in the history
Use standard routine for queue purging.

Signed-off-by: Wang Chen <wangchen@cn.fujitsu.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
  • Loading branch information
Wang Chen authored and Jeff Garzik committed May 22, 2008
1 parent a01b3d7 commit 288369c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/net/virtio_net.c
Original file line number Diff line number Diff line change
Expand Up @@ -470,8 +470,7 @@ static void virtnet_remove(struct virtio_device *vdev)
kfree_skb(skb);
vi->num--;
}
while ((skb = __skb_dequeue(&vi->send)) != NULL)
kfree_skb(skb);
__skb_queue_purge(&vi->send);

BUG_ON(vi->num != 0);

Expand Down

0 comments on commit 288369c

Please sign in to comment.