netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net] net: drop the packet when fails to do software segmentation or header check
@ 2014-12-18  5:57 Jason Wang
  2014-12-18 20:39 ` David Miller
  0 siblings, 1 reply; 3+ messages in thread
From: Jason Wang @ 2014-12-18  5:57 UTC (permalink / raw)
  To: davem, netdev, linux-kernel; +Cc: Jason Wang, Eric Dumazet

Commit cecda693a969816bac5e470e1d9c9c0ef5567bca ("net: keep original skb
which only needs header checking during software GSO") keeps the original
skb for packets that only needs header check, but it doesn't drop the
packet if software segmentation or header check were failed.

Fixes cecda693a969816bac5e470e1d9c9c0ef5567bca
(net: keep original skb which only needs header checking during software GSO)

Cc: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
---
Stable candidate for 3.17 and above.
---
 net/core/dev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/core/dev.c b/net/core/dev.c
index f411c28..a989f85 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -2673,7 +2673,7 @@ static struct sk_buff *validate_xmit_skb(struct sk_buff *skb, struct net_device
 
 		segs = skb_gso_segment(skb, features);
 		if (IS_ERR(segs)) {
-			segs = NULL;
+			goto out_kfree_skb;
 		} else if (segs) {
 			consume_skb(skb);
 			skb = segs;
-- 
1.9.1

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

* Re: [PATCH net] net: drop the packet when fails to do software segmentation or header check
  2014-12-18  5:57 [PATCH net] net: drop the packet when fails to do software segmentation or header check Jason Wang
@ 2014-12-18 20:39 ` David Miller
  2014-12-19  3:08   ` Jason Wang
  0 siblings, 1 reply; 3+ messages in thread
From: David Miller @ 2014-12-18 20:39 UTC (permalink / raw)
  To: jasowang; +Cc: netdev, linux-kernel, eric.dumazet

From: Jason Wang <jasowang@redhat.com>
Date: Thu, 18 Dec 2014 13:57:19 +0800

> Fixes cecda693a969816bac5e470e1d9c9c0ef5567bca

Please correct this fixes tag, it should be of the form:

Fixes: $(SHA1) ("header text of commit message")

The SHA1 ID should be reduced to 12 digits of significance.

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

* Re: [PATCH net] net: drop the packet when fails to do software segmentation or header check
  2014-12-18 20:39 ` David Miller
@ 2014-12-19  3:08   ` Jason Wang
  0 siblings, 0 replies; 3+ messages in thread
From: Jason Wang @ 2014-12-19  3:08 UTC (permalink / raw)
  To: David Miller; +Cc: netdev, linux-kernel, eric.dumazet



On Fri, Dec 19, 2014 at 4:39 AM, David Miller <davem@davemloft.net> 
wrote:
> From: Jason Wang <jasowang@redhat.com>
> Date: Thu, 18 Dec 2014 13:57:19 +0800
> 
>>  Fixes cecda693a969816bac5e470e1d9c9c0ef5567bca
> 
> Please correct this fixes tag, it should be of the form:
> 
> Fixes: $(SHA1) ("header text of commit message")
> 
> The SHA1 ID should be reduced to 12 digits of significance.

Ok, will post V2.

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

end of thread, other threads:[~2014-12-19  3:08 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-12-18  5:57 [PATCH net] net: drop the packet when fails to do software segmentation or header check Jason Wang
2014-12-18 20:39 ` David Miller
2014-12-19  3:08   ` Jason Wang

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).