svn commit: r258328 - head/sys/net

Luigi Rizzo rizzo at iet.unipi.it
Tue Nov 19 21:06:13 UTC 2013


On Mon, Nov 18, 2013 at 10:58:14PM +0000, George V. Neville-Neil wrote:
> Author: gnn
> Date: Mon Nov 18 22:58:14 2013
> New Revision: 258328
> URL: http://svnweb.freebsd.org/changeset/base/258328
> 
> Log:
>   Allow ethernet drivers to pass in packets connected via the nextpkt pointer.
>   Handling packets in this way allows drivers to amortize work during packet reception.

yes.

This is only a first step and eventually we should pass the entire
batch to the netisr handler to further reduce overhead.

Some of the followup emails suggested to change the argument from
struct mbuf * to something else.
I do think we should change it, but what we need is a struct with
head and tail pointers _and_ a counter, because sometimes the code
downstream may have to append the mbuf/batch to a queue,
and these extra fields would save iterating through the chain.

Related to this: at some point we should also address batching
in the transmit path, and for that we will eventually need to
introduce a 'more packets to come' flag to the API/mbuf so that
intermediate functions in the path will build batches before passing
them down.

cheers
luigi


More information about the svn-src-all mailing list