git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
vhost: add a flag to enable dequeue zero copy
[dpdk.git]
/
lib
/
librte_vhost
/
vhost.c
diff --git
a/lib/librte_vhost/vhost.c
b/lib/librte_vhost/vhost.c
index
dbf5d1b
..
469117a
100644
(file)
--- a/
lib/librte_vhost/vhost.c
+++ b/
lib/librte_vhost/vhost.c
@@
-291,6
+291,16
@@
vhost_set_ifname(int vid, const char *if_name, unsigned int if_len)
dev->ifname[sizeof(dev->ifname) - 1] = '\0';
}
+void
+vhost_enable_dequeue_zero_copy(int vid)
+{
+ struct virtio_net *dev = get_device(vid);
+
+ if (dev == NULL)
+ return;
+
+ dev->dequeue_zero_copy = 1;
+}
int
rte_vhost_get_numa_node(int vid)