From 766e9037cc139ee25ed93ee5ad11e1450c4b99f6 Mon Sep 17 00:00:00 2001 From: Eric Dumazet Date: Wed, 14 Oct 2009 20:40:11 -0700 Subject: net: sk_drops consolidation sock_queue_rcv_skb() can update sk_drops itself, removing need for callers to take care of it. This is more consistent since sock_queue_rcv_skb() also reads sk_drops when queueing a skb. This adds sk_drops managment to many protocols that not cared yet. Signed-off-by: Eric Dumazet Signed-off-by: David S. Miller --- net/ieee802154/dgram.c | 1 - net/ieee802154/raw.c | 1 - 2 files changed, 2 deletions(-) (limited to 'net/ieee802154') diff --git a/net/ieee802154/dgram.c b/net/ieee802154/dgram.c index 25ad956a39d..9aac5aee157 100644 --- a/net/ieee802154/dgram.c +++ b/net/ieee802154/dgram.c @@ -318,7 +318,6 @@ out: static int dgram_rcv_skb(struct sock *sk, struct sk_buff *skb) { if (sock_queue_rcv_skb(sk, skb) < 0) { - atomic_inc(&sk->sk_drops); kfree_skb(skb); return NET_RX_DROP; } diff --git a/net/ieee802154/raw.c b/net/ieee802154/raw.c index 769c8d138fc..9c9b85c0003 100644 --- a/net/ieee802154/raw.c +++ b/net/ieee802154/raw.c @@ -206,7 +206,6 @@ out: static int raw_rcv_skb(struct sock *sk, struct sk_buff *skb) { if (sock_queue_rcv_skb(sk, skb) < 0) { - atomic_inc(&sk->sk_drops); kfree_skb(skb); return NET_RX_DROP; } -- cgit v1.2.3-18-g5258