Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 19 Jan 2016 00:41:43 +0100
From:      Marius Strobl <marius@alchemy.franken.de>
To:        Kubilay Kocak <koobs@FreeBSD.org>
Cc:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   Re: svn commit: r293854 - head/sys/dev/e1000
Message-ID:  <20160118234142.GM15359@alchemy.franken.de>
In-Reply-To: <5698473F.8030203@FreeBSD.org>
References:  <201601132147.u0DLlR38017711@repo.freebsd.org> <5698473F.8030203@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Jan 15, 2016 at 12:11:27PM +1100, Kubilay Kocak wrote:
> On 14/01/2016 8:47 AM, Marius Strobl wrote:
> > Author: marius
> > Date: Wed Jan 13 21:47:27 2016
> > New Revision: 293854
> > URL: https://svnweb.freebsd.org/changeset/base/293854
> > 
> > Log:
> >   Given that em(4), lem(4) and igb(4) hardware doesn't require the
> >   alignment guarantees provided by m_defrag(9), use m_collapse(9)
> >   instead for performance reasons.
> >   While at it, sanitize the statistics softc members, i. e. retire
> >   unused ones and add SYSCTL nodes missing for actually used ones.
> >   
> >   Differential Revision:	https://reviews.freebsd.org/D4717
> > 
> > Modified:
> >   head/sys/dev/e1000/if_em.c
> >   head/sys/dev/e1000/if_em.h
> >   head/sys/dev/e1000/if_igb.c
> >   head/sys/dev/e1000/if_igb.h
> >   head/sys/dev/e1000/if_lem.c
> >   head/sys/dev/e1000/if_lem.h
> 
> What kind of performance / overhead delta can be expected for this change?
> 

Compared to m_collapse(9), m_defrag(9) is a real CPU hog. However,
bus_dmamap_load_mbuf_sg(9) should fail seldom enough with EFBIG
that you'll most likely not experience much of a difference in
practice.

Still, unnecessary use of m_defrag(9) in place of m_collapse(9)
should be avoided and at some point in time we actually had
managed to get rid of most of these cases. Unfortunately, such
code came back in a couple of drivers, mainly in vendor-supplied
ones.

> Is this worth MFC and/or Relnotes ?

The change is worth an MFC but not Relnotes.

Marius




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