[Ns-developers] a few more tap device comments
Tom Henderson
tomh at tomh.org
Fri Jun 5 21:38:48 PDT 2009
>
> Gustavo,
> Although I suggested the name TapNetDevice, in reviewing this today, I
> noticed that it is really behaving like a Tun device instead of a Tap
> device (i.e. it is not adding an Ethernet header).
>
> So, would you be amenable to naming it TunNetDevice instead?
>
> I also thought that the example was a bit unusual because the
> TunNetDevice handler is creating a Udp socket to send the datagram out,
> instead of just a raw socket. What do you think about changing it to a
> raw socket?
>
Gustavo,
I had a couple more comments:
- last release, Craig tried to add a tcpdump-like trace source
consistently across all net devices, called PromiscSniffer. Any concern
with adding it here too?
- I wasn't sure about how users were expected to call Receive() and
PromiscReceive(). In other NetDevices, there is a single Receive()
function and it calls both the rxCallback and the promiscRxCallback.
Here, those methods are separated. Are users supposed to call both of
these methods, or pick one? Was there a reason you didn't call the
promiscRxCallback from within Receive()?
Thanks,
Tom
More information about the Ns-developers
mailing list