diff options
author | Zhang Chen <zhangchen.fnst@cn.fujitsu.com> | 2017-07-04 14:53:50 +0800 |
---|---|---|
committer | Jason Wang <jasowang@redhat.com> | 2017-07-17 20:13:48 +0800 |
commit | ada1a33f9a690b95d32115b38b88a33cb66c83bd (patch) | |
tree | 791f16e563bca412faabee8dea8151d1eb25aacd /net/colo.c | |
parent | 00d5c2406bceb2eb5b77b47948311bf3ef8653a7 (diff) | |
download | qemu-ada1a33f9a690b95d32115b38b88a33cb66c83bd.zip |
net/colo.c: Make vnet_hdr_len as packet property
We can use this property flush and send packet with vnet_hdr_len.
Signed-off-by: Zhang Chen <zhangchen.fnst@cn.fujitsu.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
Diffstat (limited to 'net/colo.c')
-rw-r--r-- | net/colo.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/net/colo.c b/net/colo.c index 8cc166bc22..180eaed49a 100644 --- a/net/colo.c +++ b/net/colo.c @@ -153,13 +153,14 @@ void connection_destroy(void *opaque) g_slice_free(Connection, conn); } -Packet *packet_new(const void *data, int size) +Packet *packet_new(const void *data, int size, int vnet_hdr_len) { Packet *pkt = g_slice_new(Packet); pkt->data = g_memdup(data, size); pkt->size = size; pkt->creation_ms = qemu_clock_get_ms(QEMU_CLOCK_HOST); + pkt->vnet_hdr_len = vnet_hdr_len; return pkt; } |