From: Wang Chen Date: Thu, 22 May 2008 10:09:06 +0000 (+0800) Subject: NETFRONT: Use __skb_queue_purge() X-Git-Tag: v2.6.26-rc4~7^2~1^2~3 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=56cfe5d028687468f76e8b613c63ca41f209982d;p=linux-2.6-omap-h63xx.git NETFRONT: Use __skb_queue_purge() Use standard routine for queue purging. Signed-off-by: Wang Chen Signed-off-by: Jeff Garzik --- diff --git a/drivers/net/xen-netfront.c b/drivers/net/xen-netfront.c index 8bddff150c7..d26f69b0184 100644 --- a/drivers/net/xen-netfront.c +++ b/drivers/net/xen-netfront.c @@ -946,8 +946,7 @@ err: work_done++; } - while ((skb = __skb_dequeue(&errq))) - kfree_skb(skb); + __skb_queue_purge(&errq); work_done -= handle_incoming_queue(dev, &rxq); @@ -1079,8 +1078,7 @@ static void xennet_release_rx_bufs(struct netfront_info *np) } } - while ((skb = __skb_dequeue(&free_list)) != NULL) - dev_kfree_skb(skb); + __skb_queue_purge(&free_list); spin_unlock_bh(&np->rx_lock); }