Commit fcba67c9 authored by Linus Lüssing's avatar Linus Lüssing Committed by David S. Miller

net: fix two sparse warnings introduced by IGMP/MLD parsing exports

> net/core/skbuff.c:4108:13: sparse: incorrect type in assignment (different base types)
> net/ipv6/mcast_snoop.c:63 ipv6_mc_check_exthdrs() warn: unsigned 'offset' is never less than zero.

Introduced by 9afd85c9
("net: Export IGMP/MLD message validation code")
Reported-by: default avatarkbuild test robot <fengguang.wu@intel.com>
Signed-off-by: default avatarLinus Lüssing <linus.luessing@c0d3.blue>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent f9161585
...@@ -4093,7 +4093,7 @@ struct sk_buff *skb_checksum_trimmed(struct sk_buff *skb, ...@@ -4093,7 +4093,7 @@ struct sk_buff *skb_checksum_trimmed(struct sk_buff *skb,
{ {
struct sk_buff *skb_chk; struct sk_buff *skb_chk;
unsigned int offset = skb_transport_offset(skb); unsigned int offset = skb_transport_offset(skb);
int ret; __sum16 ret;
skb_chk = skb_checksum_maybe_trim(skb, transport_len); skb_chk = skb_checksum_maybe_trim(skb, transport_len);
if (!skb_chk) if (!skb_chk)
......
...@@ -47,7 +47,7 @@ static int ipv6_mc_check_ip6hdr(struct sk_buff *skb) ...@@ -47,7 +47,7 @@ static int ipv6_mc_check_ip6hdr(struct sk_buff *skb)
static int ipv6_mc_check_exthdrs(struct sk_buff *skb) static int ipv6_mc_check_exthdrs(struct sk_buff *skb)
{ {
const struct ipv6hdr *ip6h; const struct ipv6hdr *ip6h;
unsigned int offset; int offset;
u8 nexthdr; u8 nexthdr;
__be16 frag_off; __be16 frag_off;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment