]> git.proxmox.com Git - mirror_qemu.git/blobdiff - net/tap.c
migration: use a single I/O operation when writev_buffer is not defined
[mirror_qemu.git] / net / tap.c
index ce796997a35833343336b88f72376ec25b490de2..17bdf014a903a979044039cd7c70887496d485c7 100644 (file)
--- a/net/tap.c
+++ b/net/tap.c
 
 #include "net/tap.h"
 
-#include "hw/vhost_net.h"
-
-/* Maximum GSO packet size (64k) plus plenty of room for
- * the ethernet and virtio_net headers
- */
-#define TAP_BUFSIZE (4096 + 65536)
+#include "net/vhost_net.h"
 
 typedef struct TAPState {
     NetClientState nc;
     int fd;
     char down_script[1024];
     char down_script_arg[128];
-    uint8_t buf[TAP_BUFSIZE];
+    uint8_t buf[NET_BUFSIZE];
     bool read_poll;
     bool write_poll;
     bool using_vnet_hdr;