Re: [dpdk-dev] [PATCH] vhost: introduce rte_vhost_vring_call()

2017-12-21 Thread Maxime Coquelin
Hi Stefan, On 12/21/2017 05:41 PM, Stefan Hajnoczi wrote: +int +rte_vhost_vring_call(int vid, uint16_t vring_idx) +{ + struct virtio_net *dev; + struct vhost_virtqueue *vq; + + dev = get_device(vid); + if (!dev) + return -1; + + if (vring_idx >= VHOST_

[dpdk-dev] [PATCH] vhost: introduce rte_vhost_vring_call()

2017-12-21 Thread Stefan Hajnoczi
Users of librte_vhost currently implement the vring call operation themselves. Each caller performs the operation slightly differently. This patch introduces a new librte_vhost API called rte_vhost_vring_call() that performs the operation so that vhost-user applications don't have to duplicate it