Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 2 Jan 2013 11:06:55 +0900
From:      YongHyeon PYUN <pyunyh@gmail.com>
To:        Barney Cordoba <barney_cordoba@yahoo.com>
Cc:        Garrett Cooper <yanegomi@gmail.com>, freebsd-net@freebsd.org, Adrian Chadd <adrian@freebsd.org>, David Christensen <davidch@freebsd.org>, linimon@freebsd.org
Subject:   Re: kern/174851: [bxe] [patch] UDP checksum offload is wrong in bxe driver
Message-ID:  <20130102020655.GB6382@michelle.cdnetworks.com>
In-Reply-To: <1356995087.59212.YahooMailClassic@web121604.mail.ne1.yahoo.com>
References:  <CAJ-VmonQ2UXneComC_2CQ_wRrUq9eR4XD9JLezz5AEFzRqB_Lw@mail.gmail.com> <1356995087.59212.YahooMailClassic@web121604.mail.ne1.yahoo.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Dec 31, 2012 at 03:04:47PM -0800, Barney Cordoba wrote:
> 
> 
> --- On Mon, 12/31/12, Adrian Chadd <adrian@freebsd.org> wrote:
> 
> > From: Adrian Chadd <adrian@freebsd.org>
> > Subject: Re: kern/174851: [bxe] [patch] UDP checksum offload is wrong in bxe driver
> > To: "Garrett Cooper" <yanegomi@gmail.com>
> > Cc: "Barney Cordoba" <barney_cordoba@yahoo.com>, "David Christensen" <davidch@freebsd.org>, linimon@freebsd.org, freebsd-net@freebsd.org
> > Date: Monday, December 31, 2012, 2:00 PM
> > On 31 December 2012 07:58, Garrett
> > Cooper <yanegomi@gmail.com>
> > wrote:
> > 
> > > I would ask David about whether or not there was a
> > performance
> > > difference because they might have some numbers for
> > if_bxe.
> > >
> > > Not sure about the concept in general, but it seems
> > like a reasonable
> > > application protocol specific request. But by and
> > large, I agree that
> > > UDP checksumming doesn't make logical sense because it
> > adds
> > > unnecessary overhead on a L3 protocol that's assumed to
> > be unreliable.
> > 
> > People are terminating millions of VoIP calls on FreeBSD
> > devices. All using UDP.
> > 
> > I can imagine large scale VoIP gateways wanting to try and
> > benefit from this.
> > 
> 
> The statement above "assumes" that there is a benefit. voIP packets 
> are short, so the benefit of offloading is reduced. There is some
> delay added by the hardware, and there are cpu cycles used in managing
> the offload code. So those operations not only muddy the code,
> but they may not be faster than simply doing the checksum on a much, much
> faster cpu.

I'm under the impression that recent Intel controllers tend to add
more burden for driver to setup checksum offloading context. In
addition, some controllers have DMA restrictions to make checksum
offloading works such that it may add additional overhead unless
its DMA engine supports multiple outstanding reads.

As you said, checksum offloading may not make it faster but saved
CPU cycles for checksum offloading could be used for other system
activities.  You can disable checksum offloading any time when you
find it's not good for specific load.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130102020655.GB6382>