aboutsummaryrefslogtreecommitdiffstats
path: root/net/core
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@linux-foundation.org>2007-11-19 22:15:03 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-28 17:54:16 -0500
commit0adc9add7709f87995c003c0ccb085076afdc923 (patch)
tree06524f12a286746a835fe901d7732e5db391a1f0 /net/core
parent20de20beba6e9bd2e1c83696bfefa3b16cda9a74 (diff)
[NETPOLL]: Use skb_queue_purge().
Use standard routine for flushing queue. Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core')
-rw-r--r--net/core/netpoll.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/net/core/netpoll.c b/net/core/netpoll.c
index c499b5c69bed..f63a70be3cd0 100644
--- a/net/core/netpoll.c
+++ b/net/core/netpoll.c
@@ -816,11 +816,7 @@ void netpoll_cleanup(struct netpoll *np)
816 cancel_rearming_delayed_work(&npinfo->tx_work); 816 cancel_rearming_delayed_work(&npinfo->tx_work);
817 817
818 /* clean after last, unfinished work */ 818 /* clean after last, unfinished work */
819 if (!skb_queue_empty(&npinfo->txq)) { 819 __skb_queue_purge(&npinfo->txq);
820 struct sk_buff *skb;
821 skb = __skb_dequeue(&npinfo->txq);
822 kfree_skb(skb);
823 }
824 kfree(npinfo); 820 kfree(npinfo);
825 np->dev->npinfo = NULL; 821 np->dev->npinfo = NULL;
826 } 822 }