]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - net/ipv4/ip_output.c
[PATCH] eliminate duplicate rdpmc definition
[linux-2.6-omap-h63xx.git] / net / ipv4 / ip_output.c
index 38f69532a029e5ff1ddbdbd665afcff46e94abb5..ee07aec215a060fa3b980d0c88d8158a9638404b 100644 (file)
@@ -7,7 +7,7 @@
  *
  * Version:    $Id: ip_output.c,v 1.100 2002/02/01 22:01:03 davem Exp $
  *
- * Authors:    Ross Biro, <bir7@leland.Stanford.Edu>
+ * Authors:    Ross Biro
  *             Fred N. van Kempen, <waltje@uWalt.NL.Mugnet.ORG>
  *             Donald Becker, <becker@super.org>
  *             Alan Cox, <Alan.Cox@linux.org>
@@ -107,10 +107,7 @@ static int ip_dev_loopback_xmit(struct sk_buff *newskb)
        newskb->pkt_type = PACKET_LOOPBACK;
        newskb->ip_summed = CHECKSUM_UNNECESSARY;
        BUG_TRAP(newskb->dst);
-
-#ifdef CONFIG_NETFILTER_DEBUG
-       nf_debug_ip_loopback_xmit(newskb);
-#endif
+       nf_reset(newskb);
        netif_rx(newskb);
        return 0;
 }
@@ -191,10 +188,6 @@ static inline int ip_finish_output2(struct sk_buff *skb)
                skb = skb2;
        }
 
-#ifdef CONFIG_NETFILTER_DEBUG
-       nf_debug_ip_finish_output2(skb);
-#endif /*CONFIG_NETFILTER_DEBUG*/
-
        nf_reset(skb);
 
        if (hh) {
@@ -414,9 +407,6 @@ static void ip_copy_metadata(struct sk_buff *to, struct sk_buff *from)
        to->nf_bridge = from->nf_bridge;
        nf_bridge_get(to->nf_bridge);
 #endif
-#ifdef CONFIG_NETFILTER_DEBUG
-       to->nf_debug = from->nf_debug;
-#endif
 #endif
 }
 
@@ -489,6 +479,14 @@ int ip_fragment(struct sk_buff *skb, int (*output)(struct sk_buff*))
                        /* Partially cloned skb? */
                        if (skb_shared(frag))
                                goto slow_path;
+
+                       BUG_ON(frag->sk);
+                       if (skb->sk) {
+                               sock_hold(skb->sk);
+                               frag->sk = skb->sk;
+                               frag->destructor = sock_wfree;
+                               skb->truesize -= frag->truesize;
+                       }
                }
 
                /* Everything is OK. Generate! */