summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Duyck <aduyck@mirantis.com>2016-05-02 16:25:10 (GMT)
committerDavid S. Miller <davem@davemloft.net>2016-05-03 20:00:54 (GMT)
commit996e802187889f1cd412e6929c9344b92ccb78c4 (patch)
tree19e9e66c3014702dc294d9f8ca1fb7d7662f8244
parent0e28bf93a273cce0db67a17428697abb722c36b8 (diff)
downloadlinux-996e802187889f1cd412e6929c9344b92ccb78c4.tar.xz
net: Disable segmentation if checksumming is not supported
In the case of the mlx4 and mlx5 driver they do not support IPv6 checksum offload for tunnels. With this being the case we should disable GSO in addition to the checksum offload features when we find that a device cannot perform a checksum on a given packet type. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--net/core/dev.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/core/dev.c b/net/core/dev.c
index 77a71cd..5c925ac 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -2802,7 +2802,7 @@ static netdev_features_t harmonize_features(struct sk_buff *skb,
if (skb->ip_summed != CHECKSUM_NONE &&
!can_checksum_protocol(features, type)) {
- features &= ~NETIF_F_CSUM_MASK;
+ features &= ~(NETIF_F_CSUM_MASK | NETIF_F_GSO_MASK);
} else if (illegal_highdma(skb->dev, skb)) {
features &= ~NETIF_F_SG;
}