unsigned socket_id = rte_socket_id();
u32 offset = 0;
-#if RTE_VERSION >= RTE_VERSION_NUM(2, 2, 0, 0)
offset = queue_id * VIRTIO_QNUM;
struct vhost_virtqueue *vq =
if (PREDICT_FALSE(!vq->enabled))
return 0;
-#else
- if (PREDICT_FALSE(!xd->vu_is_running))
- return 0;
-#endif
struct rte_mbuf **pkts = xd->rx_vectors[queue_id];
while (n_left) {
xd->stats.imissed -
xd->last_stats.imissed);
}
-#if RTE_VERSION >= RTE_VERSION_NUM(2, 2, 0, 0)
rxerrors = xd->stats.ierrors;
last_rxerrors = xd->last_stats.ierrors;
-#else
- rxerrors = xd->stats.ibadcrc
- + xd->stats.ibadlen + xd->stats.ierrors;
- last_rxerrors = xd->last_stats.ibadcrc
- + xd->last_stats.ibadlen + xd->last_stats.ierrors;
-#endif
if (PREDICT_FALSE (rxerrors != last_rxerrors))
{