cvs commit: src/sys/net if_edsc.c

Yar Tikhiy yar at comp.chem.msu.su
Mon Mar 26 09:59:36 UTC 2007


On Mon, Mar 26, 2007 at 01:10:00PM +0400, Gleb Smirnoff wrote:
> On Mon, Mar 26, 2007 at 04:50:06AM +0000, Yar Tikhiy wrote:
> Y> yar         2007-03-26 04:50:06 UTC
> Y> 
> Y>   FreeBSD src repository
> Y> 
> Y>   Added files:
> Y>     sys/net              if_edsc.c 
> Y>   Log:
> Y>   Introduce a new toy interface, edsc(4).  It's a discard interface
> Y>   imitating an Ethernet device, so vlan(4) and if_bridge(4) can be
> Y>   attached to it for testing and benchmarking purposes.  Its source
> Y>   can be an introduction to the anatomy of a network interface driver
> Y>   due to its simplicity as well as to a bunch of comments in it.
> Y>   
> Y>   (The rest of needed changes were in my previous commit, which got
> Y>   interrupted in the middle.  Alas, CVS commits are not atomic.)
> 
> I am surprised that you didn't use ng_eiface(4) for the same purpose.

No reason for surprise, I tried to.

> If you attach ng_hole(4) to the ng_eiface, then you'll get the same
> functionality as edsc(4). But if you attach with ngctl(8) to the
> interface via ng_socket(4) you will get a hex dump of the frames
> sent to the interface.
> 
> AFAIK, the edsc(4)'s functionality is already present in the system.

Functionality, but not speed.  I think I explained on -net why I
needed edsc(4): ng_eiface+ng_hole just couldn't consume a gigabit
flow for me.  Perhaps I didn't mention an important detail: I was
interested in pps rate, so I used minimal packets, and the callback
mechanism of ng_eiface(4) was falling far behind rates as high as 1Mpps.

-- 
Yar


More information about the cvs-src mailing list