NETMAP and off-by-one?
Slawa Olhovchenkov
slw at zxy.spb.ru
Fri Nov 13 21:30:48 UTC 2015
I am see strange things: like NETMAP stop transmit after `head` and `cur`
touch `tail`.
But:
/*
* check if space is available in the ring.
*/
static inline int
nm_ring_empty(struct netmap_ring *ring)
{
return (ring->cur == ring->tail);
}
i.e. if cur == (tail-1) mod ring_size -- space is available in the
ring and I can put packet in output buffer.
After put this packet ring is full, but no transmiting.
This is bug?
More information about the freebsd-stable
mailing list