Commit 808db80a authored by Eric Dumazet's avatar Eric Dumazet Committed by David S. Miller

ipv6: call consume_skb() in frag/reassembly

Some kfree_skb() calls should be replaced by consume_skb() to avoid
drop_monitor/dropwatch false positives.
Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 08157984
...@@ -210,7 +210,7 @@ int ip6_xmit(struct sock *sk, struct sk_buff *skb, struct flowi6 *fl6, ...@@ -210,7 +210,7 @@ int ip6_xmit(struct sock *sk, struct sk_buff *skb, struct flowi6 *fl6,
kfree_skb(skb); kfree_skb(skb);
return -ENOBUFS; return -ENOBUFS;
} }
kfree_skb(skb); consume_skb(skb);
skb = skb2; skb = skb2;
skb_set_owner_w(skb, sk); skb_set_owner_w(skb, sk);
} }
...@@ -889,7 +889,7 @@ int ip6_fragment(struct sk_buff *skb, int (*output)(struct sk_buff *)) ...@@ -889,7 +889,7 @@ int ip6_fragment(struct sk_buff *skb, int (*output)(struct sk_buff *))
} }
IP6_INC_STATS(net, ip6_dst_idev(skb_dst(skb)), IP6_INC_STATS(net, ip6_dst_idev(skb_dst(skb)),
IPSTATS_MIB_FRAGOKS); IPSTATS_MIB_FRAGOKS);
kfree_skb(skb); consume_skb(skb);
return err; return err;
fail: fail:
......
...@@ -433,7 +433,7 @@ static int ip6_frag_reasm(struct frag_queue *fq, struct sk_buff *prev, ...@@ -433,7 +433,7 @@ static int ip6_frag_reasm(struct frag_queue *fq, struct sk_buff *prev,
skb_morph(head, fq->q.fragments); skb_morph(head, fq->q.fragments);
head->next = fq->q.fragments->next; head->next = fq->q.fragments->next;
kfree_skb(fq->q.fragments); consume_skb(fq->q.fragments);
fq->q.fragments = head; fq->q.fragments = head;
} }
......
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