Skip to content

Commit d6acfeb

Browse files
felix-caviumdavem330
authored andcommitted
vxlan: vxlan dev should inherit lowerdev's gso_max_size
vxlan dev currently ignores lowerdev's gso_max_size, which adversely affects TSO performance of liquidio if it's the lowerdev. Egress TCP packets' skb->len often exceed liquidio's advertised gso_max_size. This may happen on other NIC drivers. Fix it by assigning lowerdev's gso_max_size to that of vxlan dev. Might as well do likewise for gso_max_segs. Single flow TSO throughput of liquidio as lowerdev (using iperf3): Before the patch: 139 Mbps After the patch : 8.68 Gbps Percent increase: 6,144 % Signed-off-by: Felix Manlunas <[email protected]> Signed-off-by: Satanand Burla <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 6c7c98b commit d6acfeb

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

drivers/net/vxlan.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2926,6 +2926,11 @@ static int vxlan_dev_configure(struct net *src_net, struct net_device *dev,
29262926
return -EINVAL;
29272927
}
29282928

2929+
if (lowerdev) {
2930+
dev->gso_max_size = lowerdev->gso_max_size;
2931+
dev->gso_max_segs = lowerdev->gso_max_segs;
2932+
}
2933+
29292934
if (conf->mtu) {
29302935
int max_mtu = ETH_MAX_MTU;
29312936

0 commit comments

Comments
 (0)