vhost_net: basic polling support
This patch tries to poll for new added tx buffer or socket receive queue for a while at the end of tx/rx processing. The maximum time spent on polling were specified through a new kind of vring ioctl. Signed-off-by: Jason Wang <jasowang@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
d4a60603fa
commit
0308813724
4 changed files with 94 additions and 5 deletions
|
|
@ -126,6 +126,12 @@ struct vhost_memory {
|
|||
#define VHOST_SET_VRING_CALL _IOW(VHOST_VIRTIO, 0x21, struct vhost_vring_file)
|
||||
/* Set eventfd to signal an error */
|
||||
#define VHOST_SET_VRING_ERR _IOW(VHOST_VIRTIO, 0x22, struct vhost_vring_file)
|
||||
/* Set busy loop timeout (in us) */
|
||||
#define VHOST_SET_VRING_BUSYLOOP_TIMEOUT _IOW(VHOST_VIRTIO, 0x23, \
|
||||
struct vhost_vring_state)
|
||||
/* Get busy loop timeout (in us) */
|
||||
#define VHOST_GET_VRING_BUSYLOOP_TIMEOUT _IOW(VHOST_VIRTIO, 0x24, \
|
||||
struct vhost_vring_state)
|
||||
|
||||
/* VHOST_NET specific defines */
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue