net: Use __skb_pagelen() directly in skb_cow_data()
[linux-2.6-microblaze.git] / net / core / skbuff.c
index 4e2edfb..97ad652 100644 (file)
@@ -4413,7 +4413,7 @@ int skb_cow_data(struct sk_buff *skb, int tailbits, struct sk_buff **trailer)
         * at the moment even if they are anonymous).
         */
        if ((skb_cloned(skb) || skb_shinfo(skb)->nr_frags) &&
-           __pskb_pull_tail(skb, skb_pagelen(skb)-skb_headlen(skb)) == NULL)
+           !__pskb_pull_tail(skb, __skb_pagelen(skb)))
                return -ENOMEM;
 
        /* Easy case. Most of packets will go this way. */