net/pcap: enable infinitely Rx a pcap file
It can be useful to use pcap files for some rudimental performance
testing. This patch enables this functionality in the pcap driver.
At a high level, this works by creating a ring of sufficient size to
store the packets in the pcap file passed to the application. When the
rx function for this mode is called, packets are dequeued from the ring
for use by the application and also enqueued back on to the ring to be
"received" again.
A tx_drop mode is also added since transmitting to a tx_pcap file isn't
desirable at a high traffic rate.
Jumbo frames are not supported in this mode. When filling the ring at rx
queue setup time, the presence of multi segment mbufs is checked for.
The PMD will exit on detection of these multi segment mbufs.
Signed-off-by: Cian Ferriter <cian.ferriter@intel.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>