]> err.no Git - linux-2.6/commitdiff
[IPoIB] no need to set skb->dev right before freeing skb
authorRoland Dreier <rolandd@cisco.com>
Mon, 7 Nov 2005 18:49:38 +0000 (10:49 -0800)
committerRoland Dreier <rolandd@cisco.com>
Thu, 10 Nov 2005 18:22:50 +0000 (10:22 -0800)
For cut-and-paste reasons, the IPoIB driver was setting skb->dev right
before calling dev_kfree_skb_any().  Get rid of this.

Signed-off-by: Roland Dreier <rolandd@cisco.com>
drivers/infiniband/ulp/ipoib/ipoib_multicast.c

index 87096939e0b6a8ad0fd765785a7d1722e135e53e..c33ed87f9dff5c2efdf04ed6a4352e3bea5af950 100644 (file)
@@ -120,12 +120,8 @@ static void ipoib_mcast_free(struct ipoib_mcast *mcast)
        if (mcast->ah)
                ipoib_put_ah(mcast->ah);
 
-       while (!skb_queue_empty(&mcast->pkt_queue)) {
-               struct sk_buff *skb = skb_dequeue(&mcast->pkt_queue);
-
-               skb->dev = dev;
-               dev_kfree_skb_any(skb);
-       }
+       while (!skb_queue_empty(&mcast->pkt_queue))
+               dev_kfree_skb_any(skb_dequeue(&mcast->pkt_queue));
 
        kfree(mcast);
 }
@@ -317,13 +313,8 @@ ipoib_mcast_sendonly_join_complete(int status,
                                        IPOIB_GID_ARG(mcast->mcmember.mgid), status);
 
                /* Flush out any queued packets */
-               while (!skb_queue_empty(&mcast->pkt_queue)) {
-                       struct sk_buff *skb = skb_dequeue(&mcast->pkt_queue);
-
-                       skb->dev = dev;
-
-                       dev_kfree_skb_any(skb);
-               }
+               while (!skb_queue_empty(&mcast->pkt_queue))
+                       dev_kfree_skb_any(skb_dequeue(&mcast->pkt_queue));
 
                /* Clear the busy flag so we try again */
                clear_bit(IPOIB_MCAST_FLAG_BUSY, &mcast->flags);