Re: [PATCH 01/11] netpoll: use skb_queue_purge

2007-11-19 Thread David Miller
From: Stephen Hemminger <[EMAIL PROTECTED]>
Date: Sat, 03 Nov 2007 11:43:15 -0700

> Use standard route for flushing queue.
> 
> Signed-off-by: Stephen Hemminger <[EMAIL PROTECTED]>

Applied to net-2.6.25, thanks!
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 01/11] netpoll: use skb_queue_purge

2007-11-03 Thread Stephen Hemminger
Use standard route for flushing queue.

Signed-off-by: Stephen Hemminger <[EMAIL PROTECTED]>

--- a/net/core/netpoll.c2007-11-03 09:13:16.0 -0700
+++ b/net/core/netpoll.c2007-11-03 09:14:05.0 -0700
@@ -816,11 +812,7 @@ void netpoll_cleanup(struct netpoll *np)
cancel_rearming_delayed_work(&npinfo->tx_work);
 
/* clean after last, unfinished work */
-   if (!skb_queue_empty(&npinfo->txq)) {
-   struct sk_buff *skb;
-   skb = __skb_dequeue(&npinfo->txq);
-   kfree_skb(skb);
-   }
+   __skb_queue_purge(&npinfo->txq);
kfree(npinfo);
np->dev->npinfo = NULL;
}

-- 
Stephen Hemminger <[EMAIL PROTECTED]>

-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html