net: Change skb_ensure_writable()'s write_len param to unsigned int type
authorLiu Jian <liujian56@huawei.com>
Sat, 16 Apr 2022 10:58:00 +0000 (18:58 +0800)
committerDaniel Borkmann <daniel@iogearbox.net>
Wed, 20 Apr 2022 21:48:22 +0000 (23:48 +0200)
Both pskb_may_pull() and skb_clone_writable()'s length parameters are of
type unsigned int already. Therefore, change this function's write_len
param to unsigned int type.

Signed-off-by: Liu Jian <liujian56@huawei.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: Song Liu <songliubraving@fb.com>
Link: https://lore.kernel.org/bpf/20220416105801.88708-3-liujian56@huawei.com
include/linux/skbuff.h
net/core/skbuff.c

index 2394441fa3dd5e256e66ca2d424f30b0a47263ae..b37c829d08e13764dfdb927c785a3a970003ee8f 100644 (file)
@@ -3885,7 +3885,7 @@ struct sk_buff *skb_segment(struct sk_buff *skb, netdev_features_t features);
 struct sk_buff *skb_segment_list(struct sk_buff *skb, netdev_features_t features,
                                 unsigned int offset);
 struct sk_buff *skb_vlan_untag(struct sk_buff *skb);
-int skb_ensure_writable(struct sk_buff *skb, int write_len);
+int skb_ensure_writable(struct sk_buff *skb, unsigned int write_len);
 int __skb_vlan_pop(struct sk_buff *skb, u16 *vlan_tci);
 int skb_vlan_pop(struct sk_buff *skb);
 int skb_vlan_push(struct sk_buff *skb, __be16 vlan_proto, u16 vlan_tci);
index 30b523fa4ad2e9be30bdefdc61f70f989c345bbf..a84e00e44ad23d0b4e4bf68500d94bb733e1557a 100644 (file)
@@ -5601,7 +5601,7 @@ err_free:
 }
 EXPORT_SYMBOL(skb_vlan_untag);
 
-int skb_ensure_writable(struct sk_buff *skb, int write_len)
+int skb_ensure_writable(struct sk_buff *skb, unsigned int write_len)
 {
        if (!pskb_may_pull(skb, write_len))
                return -ENOMEM;