uint64_t buff_addr, phys_addr;
struct vhost_virtqueue *vq;
struct vring_desc *desc;
- struct rte_mbuf *mbuf = NULL;
+ void *obj = NULL;
+ struct rte_mbuf *mbuf;
struct vpool *vpool;
hpa_type addr_type;
struct vhost_dev *vdev = (struct vhost_dev *)dev->priv;
}
} while (unlikely(phys_addr == 0));
- rte_ring_sc_dequeue(vpool->ring, (void **)&mbuf);
+ rte_ring_sc_dequeue(vpool->ring, &obj);
+ mbuf = obj;
if (unlikely(mbuf == NULL)) {
LOG_DEBUG(VHOST_DATA,
"(%"PRIu64") in attach_rxmbuf_zcp: "
"size required: %d\n",
dev->device_fh, desc->len, desc_idx, vpool->buf_size);
put_desc_to_used_list_zcp(vq, desc_idx);
- rte_ring_sp_enqueue(vpool->ring, (void *)mbuf);
+ rte_ring_sp_enqueue(vpool->ring, obj);
return;
}
{
struct mbuf_table *tx_q;
struct rte_mbuf **m_table;
- struct rte_mbuf *mbuf = NULL;
+ void *obj = NULL;
+ struct rte_mbuf *mbuf;
unsigned len, ret, offset = 0;
struct vpool *vpool;
uint16_t vlan_tag = (uint16_t)vlan_tags[(uint16_t)dev->device_fh];
/* Allocate an mbuf and populate the structure. */
vpool = &vpool_array[MAX_QUEUES + vmdq_rx_q];
- rte_ring_sc_dequeue(vpool->ring, (void **)&mbuf);
+ rte_ring_sc_dequeue(vpool->ring, &obj);
+ mbuf = obj;
if (unlikely(mbuf == NULL)) {
struct vhost_virtqueue *vq = dev->virtqueue[VIRTIO_TXQ];
RTE_LOG(ERR, VHOST_DATA,