aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/devices/virtio/node.c
diff options
context:
space:
mode:
authorMohsin Kazmi <sykazmi@cisco.com>2020-04-07 16:42:57 +0200
committerDamjan Marion <dmarion@me.com>2020-04-08 14:40:33 +0000
commit7d697185437722ffce23a2d0b8838fc390cc6c84 (patch)
tree0e16ffcfcc3c333a7ffbe488dc5c6bcfa244be54 /src/vnet/devices/virtio/node.c
parent88cecfad98d2e8b32e68b90538c2c4cb906eb204 (diff)
virtio: fix the tcp/udp checksum offloads
Some vhost-backend calculates the wrong checksum in case of tcp/udp offload when driver resets tcp/udp checksum field to '0'. Type: fix Change-Id: I1d2a9b95b3d5cc1decac38027104a04df2af4680 Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Diffstat (limited to 'src/vnet/devices/virtio/node.c')
-rw-r--r--src/vnet/devices/virtio/node.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/src/vnet/devices/virtio/node.c b/src/vnet/devices/virtio/node.c
index 78a8dd54428..3bb23662c50 100644
--- a/src/vnet/devices/virtio/node.c
+++ b/src/vnet/devices/virtio/node.c
@@ -201,7 +201,6 @@ virtio_needs_csum (vlib_buffer_t * b0, struct virtio_net_hdr_v1 *hdr,
vnet_buffer
(b0)->l4_hdr_offset);
*l4_hdr_sz = tcp_header_bytes (tcp);
- tcp->checksum = 0;
}
else if (*l4_proto == IP_PROTOCOL_UDP)
{
@@ -210,7 +209,6 @@ virtio_needs_csum (vlib_buffer_t * b0, struct virtio_net_hdr_v1 *hdr,
vnet_buffer
(b0)->l4_hdr_offset);
*l4_hdr_sz = sizeof (*udp);
- udp->checksum = 0;
}
}