| 1974 | } |
| 1975 | |
| 1976 | static __rte_always_inline int16_t |
| 1977 | virtio_dev_rx_async_packed(struct virtio_net *dev, struct vhost_virtqueue *vq, |
| 1978 | struct rte_mbuf *pkt, uint16_t *nr_descs, uint16_t *nr_buffers) |
| 1979 | __rte_exclusive_locks_required(&vq->access_lock) |
| 1980 | __rte_shared_locks_required(&vq->iotlb_lock) |
| 1981 | { |
| 1982 | struct buf_vector buf_vec[BUF_VECTOR_MAX]; |
| 1983 | |
| 1984 | if (unlikely(vhost_enqueue_async_packed(dev, vq, pkt, buf_vec, |
| 1985 | nr_descs, nr_buffers) < 0)) { |
| 1986 | VHOST_LOG_DATA(dev->ifname, DEBUG, "failed to get enough desc from vring\n"); |
| 1987 | return -1; |
| 1988 | } |
| 1989 | |
| 1990 | VHOST_LOG_DATA(dev->ifname, DEBUG, |
| 1991 | "current index %d | end index %d\n", |
| 1992 | vq->last_avail_idx, vq->last_avail_idx + *nr_descs); |
| 1993 | |
| 1994 | return 0; |
| 1995 | } |
| 1996 | |
| 1997 | static __rte_always_inline void |
| 1998 | virtio_dev_rx_async_packed_batch_enqueue(struct virtio_net *dev, |
no test coverage detected