netmap ixgbevf mtu

Vincenzo Maffione v.maffione at gmail.com
Sat Mar 17 07:19:54 UTC 2018


First, please make sure to use the latest netmap from github.

Yes, drivers in general use 2K or 4K RX buffers regardless of the MTU or
netmap buffer size.
To receive a frame larger than the RX buffer size you need multiple netmap
slots (as multiple descriptors are
used by the hardware), looking at the NS_MOREFRAG flag.
See the example code in utils/functional.c::rx_one().
Also TX may have per-slot limitations (e.g. due to the size of the NIC TX
fifo), but this is usually > 9K, so using a single descriptor per packet
should always
be ok. However, you can also use multiple slots on the TX side (see
utils/functional.c::tx_one()).

You need to set the buf_size parameter to the RX buffer size.
Currently we miss a mechanism for netmap to get the actual RX buffer size
from the NIC driver, so we assume 4K.
We need to check that buf_size is >= RX buffer size. This mechanism will be
added soon.

Cheers,
  Vincenzo

2018-03-16 23:52 GMT+01:00 Joe Buehler <aspam at cox.net>:

> Sorry, I should have added, this is LINUX if it matters.
>
> Joe Buehler wrote:
> > I am having difficulties with netmap over top of ixgbevf when attempting
> to use a large MTU (say 9000 bytes).
> >
> > Does the ixgbevf driver use 2048 byte buffers for RX regardless of the
> MTU or netmap buffer size?
> >
> > I can send large frames just fine but inbound frames are passed via
> netmap as 2048 bytes max.  It is possible that netmap is passing frames in
> multiple pieces I suppose, I haven't checked that yet -- my code is looking
> at the frame headers only at the moment so would toss trailing pieces.
> >
> > Joe Buehler
> >
> >
>
> _______________________________________________
> freebsd-net at freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-net
> To unsubscribe, send any mail to "freebsd-net-unsubscribe at freebsd.org"
>



-- 
Vincenzo Maffione


More information about the freebsd-net mailing list