[ovs-discuss] How to enable zero-copy feature of vhost-user ??

Loftus, Ciara ciara.loftus at intel.com
Wed Aug 2 08:04:23 UTC 2017


> 
> Hi,
> 
> I heard that, about vhost-user interface,
> 0 copy rx is under development,
> but 0 copy tx from a vm is already supported with both vhost-user and
> ovs-dpdk.
> 
> However, I couldn't find out how to enable that zero copy feature from
> the ovs document (/ovs/Documentation/topics/dpdk/vhost-user.rst)
> 
> Could you inform me how to enable it or where I should refer about the
> feature ?

Try this:

diff --git a/lib/netdev-dpdk.c b/lib/netdev-dpdk.c
index ea17b97..9fdae46 100644
--- a/lib/netdev-dpdk.c
+++ b/lib/netdev-dpdk.c
@@ -944,6 +944,7 @@ netdev_dpdk_vhost_construct(struct netdev *netdev)
              dpdk_get_vhost_sock_dir(), name);

     dev->vhost_driver_flags &= ~RTE_VHOST_USER_CLIENT;
+    dev->vhost_driver_flags |= RTE_VHOST_USER_DEQUEUE_ZERO_COPY;
     err = rte_vhost_driver_register(dev->vhost_id, dev->vhost_driver_flags);
     if (err) {
         VLOG_ERR("vhost-user socket device setup failure for socket %s\n",

Thanks,
Ciara

> 
> Thanks
> 
> --
> Tetsuro Nakamura
> 
> _______________________________________________
> discuss mailing list
> discuss at openvswitch.org
> https://mail.openvswitch.org/mailman/listinfo/ovs-discuss


More information about the discuss mailing list