Skip to content

Commit

Permalink
vxlan: vxlan dev should inherit lowerdev's gso_max_size
Browse files Browse the repository at this point in the history
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 <felix.manlunas@cavium.com>
Signed-off-by: Satanand Burla <satananda.burla@cavium.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Felix Manlunas authored and David S. Miller committed Apr 1, 2017
1 parent 6c7c98b commit d6acfeb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions drivers/net/vxlan.c
Original file line number Diff line number Diff line change
@@ -2926,6 +2926,11 @@ static int vxlan_dev_configure(struct net *src_net, struct net_device *dev,
return -EINVAL;
}

if (lowerdev) {
dev->gso_max_size = lowerdev->gso_max_size;
dev->gso_max_segs = lowerdev->gso_max_segs;
}

if (conf->mtu) {
int max_mtu = ETH_MAX_MTU;

0 comments on commit d6acfeb

Please sign in to comment.