backports: add __pskb_copy_fclone()
authorHauke Mehrtens <hauke@hauke-m.de>
Sun, 15 Jun 2014 22:17:15 +0000 (00:17 +0200)
committerHauke Mehrtens <hauke@hauke-m.de>
Mon, 16 Jun 2014 22:30:28 +0000 (00:30 +0200)
__pskb_copy() was renamed to __pskb_copy_fclone() in most places and
got an extra parameter, it should be safe to just ignore this extra
parameter.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
backport/backport-include/linux/skbuff.h

index 2576faf2ba498009fc29800d13a83987d0646cc9..a70766386a10dc375b8623ad2860af357803fd6d 100644 (file)
@@ -373,4 +373,14 @@ skb_set_hash(struct sk_buff *skb, __u32 hash, enum pkt_hash_types type)
 }
 #endif /* LINUX_VERSION_CODE < KERNEL_VERSION(3,14,0) */
 
+#if LINUX_VERSION_CODE < KERNEL_VERSION(3,16,0)
+#define __pskb_copy_fclone LINUX_BACKPORT(__pskb_copy_fclone)
+static inline struct sk_buff *__pskb_copy_fclone(struct sk_buff *skb,
+                                                int headroom, gfp_t gfp_mask,
+                                                bool fclone)
+{
+       return __pskb_copy(skb, headroom, gfp_mask);
+}
+#endif
+
 #endif /* __BACKPORT_SKBUFF_H */