netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Michael Chan" <mchan@broadcom.com>
To: "David Miller" <davem@davemloft.net>
Cc: bristuccia@starentnetworks.com, "netdev" <netdev@vger.kernel.org>
Subject: Re: 2.6.20.7 mss negotiation and path mtu discovery mostly broken?
Date: Thu, 03 May 2007 16:24:20 -0700	[thread overview]
Message-ID: <1178234660.4887.3.camel@dell> (raw)
In-Reply-To: <20070425.131602.18289973.davem@davemloft.net>

On Wed, 2007-04-25 at 13:16 -0700, David Miller wrote:
> From: "Ristuccia, Brian" <bristuccia@starentnetworks.com>
> Date: Wed, 25 Apr 2007 16:11:51 -0400
> 
> > > I'm seeing a 
> > > problem where the kernel attempts to send packets with a MSS 
> > > larger than the one negotiated when the TCP connection is 
> > > established. Even after ICMP "can't fragment" messages 
> > > arrive, the kernel still attempts to increase the MSS rather 
> > > aggressively. The end result is extremely poor throughput 
> > > when sending to a network with a smaller MTU. 
> > 
> > I've tracked this problem to the TSO feature in the bnx2 driver. Turning
> > off TSO with "ethtool -K eth1 tso off" seems to work around the problem.
> > It appears that the bnx2 device is not using the correct mss when
> > performing segmentation offload. 
> 
> Thanks for narrowing it down like that.
> 
> Michael can you have a look?  Is the bnx2 firmware using the MTU
> setting in the device and ignoring the passed in MSS or something
> like that?
> 

This should fix it.  I will send this and other selected BNX2 fixes to
stable as well.  Thanks.

[BNX2]: Fix TSO problem with small MSS.

Remove the check for skb->len greater than MTU when doing TSO.  When
the destination has a smaller MSS than the source, a TSO packet may
be smaller than the MTU at the source and we still need to process it
as a TSO packet.

Thanks to Brian Ristuccia <bristuccia@starentnetworks.com> for
reporting the problem.

Signed-off-by: Michael Chan <mchan@broadcom.com>

diff --git a/drivers/net/bnx2.c b/drivers/net/bnx2.c
index 605347f..88b33c6 100644
--- a/drivers/net/bnx2.c
+++ b/drivers/net/bnx2.c
@@ -4836,8 +4836,7 @@ bnx2_start_xmit(struct sk_buff *skb, struct net_device *dev)
 		vlan_tag_flags |=
 			(TX_BD_FLAGS_VLAN_TAG | (vlan_tx_tag_get(skb) << 16));
 	}
-	if ((mss = skb_shinfo(skb)->gso_size) &&
-		(skb->len > (bp->dev->mtu + ETH_HLEN))) {
+	if ((mss = skb_shinfo(skb)->gso_size)) {
 		u32 tcp_opt_len, ip_tcp_len;
 		struct iphdr *iph;
 



  reply	other threads:[~2007-05-03 22:37 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-04-25 20:09 2.6.20.7 mss negotiation and path mtu discovery mostly broken? Ristuccia, Brian
2007-04-25 20:11 ` Ristuccia, Brian
2007-04-25 20:16   ` David Miller
2007-05-03 23:24     ` Michael Chan [this message]
2007-05-04  0:23       ` David Miller
2007-04-25 22:48 ` Herbert Xu
2007-04-26 15:53   ` Ristuccia, Brian
     [not found] <7CCD07160348804497EF29E9EA5560D7020F6203@exchtewks2.starentnetworks.com>
2007-04-25 15:10 ` Andi Kleen
2007-04-25 14:31   ` Ristuccia, Brian

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1178234660.4887.3.camel@dell \
    --to=mchan@broadcom.com \
    --cc=bristuccia@starentnetworks.com \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).