linux 2.6.16.38 w/ vs2.0.3-rc1
[linux-2.6.git] / net / llc / llc_input.c
index 94d2368..8f3addf 100644 (file)
@@ -118,8 +118,7 @@ static inline int llc_fixup_skb(struct sk_buff *skb)
                u16 pdulen = eth_hdr(skb)->h_proto,
                    data_size = ntohs(pdulen) - llc_len;
 
-               if (unlikely(pskb_trim_rcsum(skb, data_size)))
-                       return 0;
+               skb_trim(skb, data_size);
        }
        return 1;
 }
@@ -142,8 +141,6 @@ int llc_rcv(struct sk_buff *skb, struct net_device *dev,
        struct llc_sap *sap;
        struct llc_pdu_sn *pdu;
        int dest;
-       int (*rcv)(struct sk_buff *, struct net_device *,
-                  struct packet_type *, struct net_device *);
 
        /*
         * When the interface is in promisc. mode, drop all the crap that it
@@ -171,11 +168,9 @@ int llc_rcv(struct sk_buff *skb, struct net_device *dev,
         * First the upper layer protocols that don't need the full
         * LLC functionality
         */
-       rcv = rcu_dereference(sap->rcv_func);
-       if (rcv) {
-               struct sk_buff *cskb = skb_clone(skb, GFP_ATOMIC);
-               if (cskb)
-                       rcv(cskb, dev, pt, orig_dev);
+       if (sap->rcv_func) {
+               sap->rcv_func(skb, dev, pt, orig_dev);
+               goto out_put;
        }
        dest = llc_pdu_type(skb);
        if (unlikely(!dest || !llc_type_handlers[dest - 1]))