Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
[cascardo/linux.git] / net / ipv4 / udp_offload.c
index 5d396b9..4c519c1 100644 (file)
@@ -61,8 +61,9 @@ static struct sk_buff *__skb_udp_tunnel_segment(struct sk_buff *skb,
 
        /* Try to offload checksum if possible */
        offload_csum = !!(need_csum &&
-                         (skb->dev->features &
-                          (is_ipv6 ? NETIF_F_V6_CSUM : NETIF_F_V4_CSUM)));
+                         ((skb->dev->features & NETIF_F_HW_CSUM) ||
+                          (skb->dev->features & (is_ipv6 ?
+                           NETIF_F_IPV6_CSUM : NETIF_F_IP_CSUM))));
 
        /* segment inner packet. */
        enc_features = skb->dev->hw_enc_features & features;