Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 10 Jul 2008 15:52:11 -0400
From:      gnn@FreeBSD.org
To:        Robert Watson <rwatson@FreeBSD.org>
Cc:        net@FreeBSD.org
Subject:   Re: What's the deal with hardware checksum and net.inet.udp.checksum?
Message-ID:  <m2prpljz4k.wl%gnn@neville-neil.com>
In-Reply-To: <20080710114028.T34050@fledge.watson.org>
References:  <m2fxqilpgg.wl%gnn@neville-neil.com> <20080710114028.T34050@fledge.watson.org>

next in thread | previous in thread | raw e-mail | index | archive | help
At Thu, 10 Jul 2008 11:43:23 +0100 (BST),
rwatson wrote:
> 
> On Wed, 9 Jul 2008, gnn@freebsd.org wrote:
> 
> > I would assume that if a card, say the em, has hardware TX checksum that the 
> > UDP checksum could be calculated by the hardware, but this seems not to be 
> > the case.  The manual pages are unhelpful in this regard.
> 
> On the whole, they should be generated in hardware as long as it's
> not administratively disabled with ifconfig, and as long as there
> aren't know bugs in the hardware for the rev you're using.  Just for
> example, hardware checksumming is disabled in software for quite a
> few early 1gbps cards due to bugs in the hardware causing rather
> nasty side effects.  What specific problem are you seeing?  We do do
> a software checksum of the pseudo-header, but the UDP data should be
> checksummed by hardware.
> 
> (The usual test for hardware checksum being enabled on transmit is
> to tcpdump the interface and see tcpdump reporting lots of bad
> checksums, as the BPF capture happens before hardware checksumming
> is run -- in principle on the receive side that shouldn't happen!)
> 

If the sysctl it turned off on the transmitter then the receiving
machine sees UDP checksums of 0.

Best,
George



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?m2prpljz4k.wl%gnn>