[prev in list] [next in list] [prev in thread] [next in thread]
List: linux-backports
Subject: [PATCH 04/21] header: skbuff: fix signature of skb_put(), skb_push() and ()
From: Hauke Mehrtens <hauke () hauke-m ! de>
Date: 2017-08-21 22:28:00
Message-ID: 20170821222817.17376-5-hauke () hauke-m ! de
[Download RAW message or body]
In older kernel versions these functions returned a unsigned char*, now
they return a void *.
This change was done in upstream commit d58ff35122847a8 ("networking:
make skb_push & __skb_push return void pointers")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
backport/backport-include/linux/skbuff.h | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
diff --git a/backport/backport-include/linux/skbuff.h b/backport/backport-include/linux/skbuff.h
index 09894a96..61f3b98f 100644
--- a/backport/backport-include/linux/skbuff.h
+++ b/backport/backport-include/linux/skbuff.h
@@ -316,6 +316,24 @@ __u32 skb_get_hash_perturb(const struct sk_buff *skb, u32 perturb)
#endif
#if LINUX_VERSION_IS_LESS(4,13,0)
+static inline void *backport_skb_put(struct sk_buff *skb, unsigned int len)
+{
+ return skb_put(skb, len);
+}
+#define skb_put LINUX_BACKPORT(skb_put)
+
+static inline void *backport_skb_push(struct sk_buff *skb, unsigned int len)
+{
+ return skb_push(skb, len);
+}
+#define skb_push LINUX_BACKPORT(skb_push)
+
+static inline void *backport___skb_push(struct sk_buff *skb, unsigned int len)
+{
+ return __skb_push(skb, len);
+}
+#define __skb_push LINUX_BACKPORT(__skb_push)
+
static inline void *skb_put_zero(struct sk_buff *skb, unsigned int len)
{
void *tmp = skb_put(skb, len);
--
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe backports" in
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic