netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] packet: uses kfree_skb() for drop.
@ 2016-04-06 16:54 Weongyo Jeong
  2016-04-06 17:27 ` Willem de Bruijn
  0 siblings, 1 reply; 3+ messages in thread
From: Weongyo Jeong @ 2016-04-06 16:54 UTC (permalink / raw)
  To: netdev; +Cc: Weongyo Jeong, David S. Miller, Willem de Bruijn

consume_skb() isn't for drop or error cases.  kfree_skb() is more proper
one.

Signed-off-by: Weongyo Jeong <weongyo.linux@gmail.com>
---
 net/packet/af_packet.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/packet/af_packet.c b/net/packet/af_packet.c
index 1ecfa71..a75d5bf 100644
--- a/net/packet/af_packet.c
+++ b/net/packet/af_packet.c
@@ -2141,7 +2141,7 @@ drop_n_restore:
 		skb->len = skb_len;
 	}
 drop:
-	consume_skb(skb);
+	kfree_skb(skb);
 	return 0;
 }
 
-- 
2.1.3

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-04-06 18:10 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-06 16:54 [PATCH] packet: uses kfree_skb() for drop Weongyo Jeong
2016-04-06 17:27 ` Willem de Bruijn
2016-04-06 18:10   ` Weongyo Jeong

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).