Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F151687984
D29331.id85981.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D29331.id85981.diff
View Options
diff --git a/sys/dev/virtio/network/if_vtnet.c b/sys/dev/virtio/network/if_vtnet.c
--- a/sys/dev/virtio/network/if_vtnet.c
+++ b/sys/dev/virtio/network/if_vtnet.c
@@ -2389,7 +2389,7 @@
}
static int
-vtnet_txq_offload_tso(struct vtnet_txq *txq, struct mbuf *m, int flags,
+vtnet_txq_offload_tso(struct vtnet_txq *txq, struct mbuf *m, int eth_type,
int offset, struct virtio_net_hdr *hdr)
{
static struct timeval lastecn;
@@ -2407,8 +2407,8 @@
hdr->hdr_len = vtnet_gtoh16(sc, offset + (tcp->th_off << 2));
hdr->gso_size = vtnet_gtoh16(sc, m->m_pkthdr.tso_segsz);
- hdr->gso_type = (flags & CSUM_IP_TSO) ?
- VIRTIO_NET_HDR_GSO_TCPV4 : VIRTIO_NET_HDR_GSO_TCPV6;
+ hdr->gso_type = eth_type == ETHERTYPE_IP ? VIRTIO_NET_HDR_GSO_TCPV4 :
+ VIRTIO_NET_HDR_GSO_TCPV6;
if (__predict_false(tcp->th_flags & TH_CWR)) {
/*
@@ -2474,7 +2474,7 @@
goto drop;
}
- error = vtnet_txq_offload_tso(txq, m, flags, csum_start, hdr);
+ error = vtnet_txq_offload_tso(txq, m, etype, csum_start, hdr);
if (error)
goto drop;
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Apr 11, 12:52 AM (15 h, 12 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
31258336
Default Alt Text
D29331.id85981.diff (1 KB)
Attached To
Mode
D29331: Fix TSO for TCP/IPv6
Attached
Detach File
Event Timeline
Log In to Comment