search for: virtio_net_handle_tx

Displaying 14 results from an estimated 14 matches for "virtio_net_handle_tx".

Did you mean: virtio_net_handle_rx
2008 Jan 09
2
[PATCH] Increase the tx queue to 512 descriptors to fix performance problem.
..._net_init(PCIBus *bus, NICInfo *nd, int devfn) n->vdev.update_config = virtio_net_update_config; n->vdev.get_features = virtio_net_get_features; n->rx_vq = virtio_add_queue(&n->vdev, 512, virtio_net_handle_rx); - n->tx_vq = virtio_add_queue(&n->vdev, 128, virtio_net_handle_tx); + n->tx_vq = virtio_add_queue(&n->vdev, 512, virtio_net_handle_tx); n->can_receive = 0; memcpy(n->mac, nd->macaddr, 6); n->vc = qemu_new_vlan_client(nd->vlan, virtio_net_receive, -- 1.5.3.7
2008 Jan 09
2
[PATCH] Increase the tx queue to 512 descriptors to fix performance problem.
..._net_init(PCIBus *bus, NICInfo *nd, int devfn) n->vdev.update_config = virtio_net_update_config; n->vdev.get_features = virtio_net_get_features; n->rx_vq = virtio_add_queue(&n->vdev, 512, virtio_net_handle_rx); - n->tx_vq = virtio_add_queue(&n->vdev, 128, virtio_net_handle_tx); + n->tx_vq = virtio_add_queue(&n->vdev, 512, virtio_net_handle_tx); n->can_receive = 0; memcpy(n->mac, nd->macaddr, 6); n->vc = qemu_new_vlan_client(nd->vlan, virtio_net_receive, -- 1.5.3.7
2007 Dec 21
0
[Virtio-for-kvm] [PATCH 2/7] userspace virtio
...g[i].iov_len, size - offset); + memcpy(elem.in_sg[i].iov_base, buf + offset, len); + offset += len; + i++; + } + + /* signal other side */ + virtqueue_push(n->rx_vq, &elem, sizeof(*hdr) + offset); + virtio_notify(&n->vdev, n->rx_vq); +} + +/* TX */ +static void virtio_net_handle_tx(VirtIODevice *vdev, VirtQueue *vq) +{ + VirtIONet *n = to_virtio_net(vdev); + VirtQueueElement elem; + + while (virtqueue_pop(vq, &elem)) { + int i; + size_t len = 0; + + /* ignore the header for now */ + for (i = 1; i < elem.out_num; i++) { + qemu_send_packet(n-&...
2007 Dec 21
0
[Virtio-for-kvm] [PATCH 2/7] userspace virtio
...g[i].iov_len, size - offset); + memcpy(elem.in_sg[i].iov_base, buf + offset, len); + offset += len; + i++; + } + + /* signal other side */ + virtqueue_push(n->rx_vq, &elem, sizeof(*hdr) + offset); + virtio_notify(&n->vdev, n->rx_vq); +} + +/* TX */ +static void virtio_net_handle_tx(VirtIODevice *vdev, VirtQueue *vq) +{ + VirtIONet *n = to_virtio_net(vdev); + VirtQueueElement elem; + + while (virtqueue_pop(vq, &elem)) { + int i; + size_t len = 0; + + /* ignore the header for now */ + for (i = 1; i < elem.out_num; i++) { + qemu_send_packet(n-&...
2007 Dec 21
2
[Virtio-for-kvm] [PATCH 7/7] userspace virtio
.../* signal other side */ - virtqueue_push(n->rx_vq, &elem, sizeof(*hdr) + offset); - virtio_notify(&n->vdev, n->rx_vq); } /* TX */ @@ -174,8 +218,12 @@ void *virtio_net_init(PCIBus *bus, NICInfo *nd, int devfn) n->tx_vq = virtio_add_queue(&n->vdev, 128, virtio_net_handle_tx); n->can_receive = 0; memcpy(n->mac, nd->macaddr, 6); - n->vc = qemu_new_vlan_client(nd->vlan, virtio_net_receive, + n->vc = qemu_new_vlan_client(nd->vlan, NULL, virtio_net_can_receive, n); + n->tap_fd = get_tap_fd(n->vc->vlan->f...
2007 Dec 21
2
[Virtio-for-kvm] [PATCH 7/7] userspace virtio
.../* signal other side */ - virtqueue_push(n->rx_vq, &elem, sizeof(*hdr) + offset); - virtio_notify(&n->vdev, n->rx_vq); } /* TX */ @@ -174,8 +218,12 @@ void *virtio_net_init(PCIBus *bus, NICInfo *nd, int devfn) n->tx_vq = virtio_add_queue(&n->vdev, 128, virtio_net_handle_tx); n->can_receive = 0; memcpy(n->mac, nd->macaddr, 6); - n->vc = qemu_new_vlan_client(nd->vlan, virtio_net_receive, + n->vc = qemu_new_vlan_client(nd->vlan, NULL, virtio_net_can_receive, n); + n->tap_fd = get_tap_fd(n->vc->vlan->f...
2009 Aug 13
0
[PATCHv2 3/3] qemu-kvm: vhost-net implementation
...et_features; n->vdev.bad_features = virtio_net_bad_features; n->vdev.reset = virtio_net_reset; + n->vdev.driver_ok = virtio_net_driver_ok; n->rx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_rx); n->tx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_tx); n->ctrl_vq = virtio_add_queue(&n->vdev, 64, virtio_net_handle_ctrl); @@ -863,6 +892,7 @@ VirtIODevice *virtio_net_init(DeviceState *dev) n->vdev.nvectors = 3; else n->vdev.nvectors = dev->nd->nvectors; + n->vhost_device = dev->nd->vhos...
2009 Aug 13
0
[PATCHv2 3/3] qemu-kvm: vhost-net implementation
...et_features; n->vdev.bad_features = virtio_net_bad_features; n->vdev.reset = virtio_net_reset; + n->vdev.driver_ok = virtio_net_driver_ok; n->rx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_rx); n->tx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_tx); n->ctrl_vq = virtio_add_queue(&n->vdev, 64, virtio_net_handle_ctrl); @@ -863,6 +892,7 @@ VirtIODevice *virtio_net_init(DeviceState *dev) n->vdev.nvectors = 3; else n->vdev.nvectors = dev->nd->nvectors; + n->vhost_device = dev->nd->vhos...
2009 Aug 17
1
[PATCHv3 3/4] qemu-kvm: vhost-net implementation
...et_features; n->vdev.bad_features = virtio_net_bad_features; n->vdev.reset = virtio_net_reset; + n->vdev.driver_ok = virtio_net_driver_ok; n->rx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_rx); n->tx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_tx); n->ctrl_vq = virtio_add_queue(&n->vdev, 64, virtio_net_handle_ctrl); @@ -863,6 +892,7 @@ VirtIODevice *virtio_net_init(DeviceState *dev) n->vdev.nvectors = 3; else n->vdev.nvectors = dev->nd->nvectors; + n->vhost_device = dev->nd->vhos...
2009 Aug 17
1
[PATCHv3 3/4] qemu-kvm: vhost-net implementation
...et_features; n->vdev.bad_features = virtio_net_bad_features; n->vdev.reset = virtio_net_reset; + n->vdev.driver_ok = virtio_net_driver_ok; n->rx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_rx); n->tx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_tx); n->ctrl_vq = virtio_add_queue(&n->vdev, 64, virtio_net_handle_ctrl); @@ -863,6 +892,7 @@ VirtIODevice *virtio_net_init(DeviceState *dev) n->vdev.nvectors = 3; else n->vdev.nvectors = dev->nd->nvectors; + n->vhost_device = dev->nd->vhos...
2009 Aug 10
0
[PATCH 3/3] qemu-kvm: vhost-net implementation
...et_features; n->vdev.bad_features = virtio_net_bad_features; n->vdev.reset = virtio_net_reset; + n->vdev.driver_ok = virtio_net_driver_ok; n->rx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_rx); n->tx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_tx); n->ctrl_vq = virtio_add_queue(&n->vdev, 64, virtio_net_handle_ctrl); @@ -864,6 +893,7 @@ VirtIODevice *virtio_net_init(DeviceState *dev) n->vdev.nvectors = 3; else n->vdev.nvectors = dev->nd->nvectors; + n->vhost_device = dev->nd->vhos...
2009 Aug 10
0
[PATCH 3/3] qemu-kvm: vhost-net implementation
...et_features; n->vdev.bad_features = virtio_net_bad_features; n->vdev.reset = virtio_net_reset; + n->vdev.driver_ok = virtio_net_driver_ok; n->rx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_rx); n->tx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_tx); n->ctrl_vq = virtio_add_queue(&n->vdev, 64, virtio_net_handle_ctrl); @@ -864,6 +893,7 @@ VirtIODevice *virtio_net_init(DeviceState *dev) n->vdev.nvectors = 3; else n->vdev.nvectors = dev->nd->nvectors; + n->vhost_device = dev->nd->vhos...
2009 Nov 02
2
[PATCHv4 6/6] qemu-kvm: vhost-net implementation
...et_features; n->vdev.bad_features = virtio_net_bad_features; n->vdev.reset = virtio_net_reset; + n->vdev.driver_ok = virtio_net_driver_ok; n->rx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_rx); n->tx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_tx); n->ctrl_vq = virtio_add_queue(&n->vdev, 64, virtio_net_handle_ctrl); @@ -864,7 +910,6 @@ VirtIODevice *virtio_net_init(DeviceState *dev) n->vdev.nvectors = 3; else n->vdev.nvectors = dev->nd->nvectors; - register_savevm("virtio-net"...
2009 Nov 02
2
[PATCHv4 6/6] qemu-kvm: vhost-net implementation
...et_features; n->vdev.bad_features = virtio_net_bad_features; n->vdev.reset = virtio_net_reset; + n->vdev.driver_ok = virtio_net_driver_ok; n->rx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_rx); n->tx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_tx); n->ctrl_vq = virtio_add_queue(&n->vdev, 64, virtio_net_handle_ctrl); @@ -864,7 +910,6 @@ VirtIODevice *virtio_net_init(DeviceState *dev) n->vdev.nvectors = 3; else n->vdev.nvectors = dev->nd->nvectors; - register_savevm("virtio-net"...