From owner-freebsd-net@FreeBSD.ORG Thu Dec 15 22:14:40 2011 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B5D92106564A for ; Thu, 15 Dec 2011 22:14:40 +0000 (UTC) (envelope-from pyunyh@gmail.com) Received: from mail-iy0-f182.google.com (mail-iy0-f182.google.com [209.85.210.182]) by mx1.freebsd.org (Postfix) with ESMTP id 7D0468FC08 for ; Thu, 15 Dec 2011 22:14:40 +0000 (UTC) Received: by iakl21 with SMTP id l21so6208730iak.13 for ; Thu, 15 Dec 2011 14:14:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=from:date:to:cc:subject:message-id:reply-to:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=mwIMjXJ3Cov7XQTs5evtUF5kklmdbi87GNWojDtKwG0=; b=Ou4yn+WUlKtPCyITeTyIYQ0UmGixBiMa+ZXdxohwxVdEfL7E8vtizhkOln1+viTXeC gPzz34ClJ7H1LBrMd4IfP09fieIodE8TGNWYiGCAZdefkNvn0ivE8YwlUa1cjQH7Aden KY17mxTPkGNItpW5ia79Y0iJjG6N+T4yLnnrQ= Received: by 10.50.46.167 with SMTP id w7mr4390661igm.88.1323987279904; Thu, 15 Dec 2011 14:14:39 -0800 (PST) Received: from pyunyh@gmail.com ([174.35.1.224]) by mx.google.com with ESMTPS id e2sm25929891ibe.0.2011.12.15.14.14.36 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 15 Dec 2011 14:14:38 -0800 (PST) Received: by pyunyh@gmail.com (sSMTP sendmail emulation); Thu, 15 Dec 2011 14:13:37 -0800 From: YongHyeon PYUN Date: Thu, 15 Dec 2011 14:13:37 -0800 To: Andrea Venturoli Message-ID: <20111215221337.GA15187@michelle.cdnetworks.com> References: <4EE8FA10.8090502@netfence.it> <20111214195918.GC11426@michelle.cdnetworks.com> <4EE91275.3060808@netfence.it> <20111214213242.GD11426@michelle.cdnetworks.com> <4EEA0153.5010305@netfence.it> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4EEA0153.5010305@netfence.it> User-Agent: Mutt/1.4.2.3i Cc: freebsd-net@freebsd.org Subject: Re: Intel 82550 Pro/100 Ethernet and TSO troubles X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: pyunyh@gmail.com List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2011 22:14:40 -0000 On Thu, Dec 15, 2011 at 03:16:51PM +0100, Andrea Venturoli wrote: > On 12/14/11 22:32, YongHyeon PYUN wrote: > > >>Wireshark showed some wrong checksums (I believe on the ICMP packet, but > >>I might remember wrong). > > > >You can check whether you received bad checksummed frames with > >netstat(1). > > I tried "netstat -ind", but it shows no Ierrs/Idrop/Oerrs/Odrop. > Use -s option which will show statistics for each network protocols. Search 'discarded for bad checksums' from the output. > > > > > >Is simple downloading from client to server is enough to trigger > >the issue? > > Yes and no. > Depending on where the client is located (on the Internet) and/or the > protocol used, I get either failures or ridicuolous performance (i.e. > 58-60kB/s without TSO vs. 1-2kB/s with TSO). > > > > > > >Packet capture that shows the problem would be great to > >know what's going on here. > > I'll send them to you privately. > > You'll see tso.dump and notso.dump: they are both from the same client > downloading the same (random) file (the file name was changed only to > prevent possible caching). > See notso.dump is perfect, while tso.dump shows a lot of potential problems. > Thanks. > > > > > >>Would you try attached patch and let me know it goes? > >Sorry, it seems extra pull up for TCP payload may not be required > >here. Try this instead. > > I see a little increase in performance (2-3kB/s instead of 1-2kB/s); > this might however well depend on external factors. Still it is very > different from what I'm get without TSO. > Thanks for testing. Based on dump file, I tried various MTU configuration and I was not able to reproduce it. By chance, are you using firewall(pf/ipfw/ipf) or bridge(4)? If I remember correctly some firewall rules are not compatible with TSO. For bridge, if one member of bridge does not support TSO, TSO should be disabled. > > > bye & Thanks > av. > > P.S. I can live well without TSO; I'm just doing this to let the > software improve. Go ahead only if *you* are interested. I do care driver stability so it would be great if I manage to address the issue. :-)