[dpdk-dev] [PATCH 10/17] vhost: export the number of vrings
Maxime Coquelin
maxime.coquelin at redhat.com
Tue Mar 14 13:33:14 CET 2017
On 03/03/2017 10:51 AM, Yuanhan Liu wrote:
> We used to use rte_vhost_get_queue_num() for telling how many vrings.
> However, the return value is the number of "queue pairs", which is
> very virtio-net specific. To make it generic, we should return the
> number of vrings instead, and let the driver do the proper translation.
> Say, virtio-net driver could turn it to the number of queue pairs by
> dividing 2.
>
> Meanwhile, mark rte_vhost_get_queue_num as deprecated.
>
> Signed-off-by: Yuanhan Liu <yuanhan.liu at linux.intel.com>
> ---
> drivers/net/vhost/rte_eth_vhost.c | 2 +-
> lib/librte_vhost/rte_vhost_version.map | 1 +
> lib/librte_vhost/rte_virtio_net.h | 17 +++++++++++++++++
> lib/librte_vhost/vhost.c | 11 +++++++++++
> 4 files changed, 30 insertions(+), 1 deletion(-)
Reviewed-by: Maxime Coquelin <maxime.coquelin at redhat.com>
Thanks,
Maxime
More information about the dev
mailing list