vserver 1.9.5.x5
[linux-2.6.git] / net / ipv4 / ip_input.c
index c7b3b60..51069c0 100644 (file)
@@ -172,7 +172,7 @@ int ip_call_ra_chain(struct sk_buff *skb)
                    (!sk->sk_bound_dev_if ||
                     sk->sk_bound_dev_if == skb->dev->ifindex)) {
                        if (skb->nh.iph->frag_off & htons(IP_MF|IP_OFFSET)) {
-                               skb = ip_defrag(skb);
+                               skb = ip_defrag(skb, IP_DEFRAG_CALL_RA_CHAIN);
                                if (skb == NULL) {
                                        read_unlock(&ip_ra_lock);
                                        return 1;
@@ -231,10 +231,9 @@ static inline int ip_local_deliver_finish(struct sk_buff *skb)
                if (raw_sk)
                        raw_v4_input(skb, skb->nh.iph, hash);
 
-               if ((ipprot = inet_protos[hash]) != NULL) {
+               if ((ipprot = rcu_dereference(inet_protos[hash])) != NULL) {
                        int ret;
 
-                       smp_read_barrier_depends();
                        if (!ipprot->no_policy &&
                            !xfrm4_policy_check(NULL, XFRM_POLICY_IN, skb)) {
                                kfree_skb(skb);
@@ -274,7 +273,7 @@ int ip_local_deliver(struct sk_buff *skb)
         */
 
        if (skb->nh.iph->frag_off & htons(IP_MF|IP_OFFSET)) {
-               skb = ip_defrag(skb);
+               skb = ip_defrag(skb, IP_DEFRAG_LOCAL_DELIVER);
                if (!skb)
                        return 0;
        }