Skip to content

Commit 64050cd

Browse files
ayalevinSaeed Mahameed
authored andcommitted
Revert "net/mlx5e: Block offload of outer header csum for UDP tunnels"
This reverts commit 6d6727d. Although the NIC doesn't support offload of outer header CSUM, using gso_partial_features allows offloading the tunnel's segmentation. The driver relies on the stack CSUM calculation of the outer header. For this, NETIF_F_GSO_UDP_TUNNEL_CSUM must be a member of the device's features. Fixes: 6d6727d ("net/mlx5e: Block offload of outer header csum for UDP tunnels") Signed-off-by: Aya Levin <[email protected]> Reviewed-by: Gal Pressman <[email protected]> Signed-off-by: Saeed Mahameed <[email protected]>
1 parent 9e72a55 commit 64050cd

File tree

1 file changed

+7
-3
lines changed
  • drivers/net/ethernet/mellanox/mlx5/core

1 file changed

+7
-3
lines changed

drivers/net/ethernet/mellanox/mlx5/core/en_main.c

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4789,9 +4789,13 @@ static void mlx5e_build_nic_netdev(struct net_device *netdev)
47894789
}
47904790

47914791
if (mlx5_vxlan_allowed(mdev->vxlan) || mlx5_geneve_tx_allowed(mdev)) {
4792-
netdev->hw_features |= NETIF_F_GSO_UDP_TUNNEL;
4793-
netdev->hw_enc_features |= NETIF_F_GSO_UDP_TUNNEL;
4794-
netdev->vlan_features |= NETIF_F_GSO_UDP_TUNNEL;
4792+
netdev->hw_features |= NETIF_F_GSO_UDP_TUNNEL |
4793+
NETIF_F_GSO_UDP_TUNNEL_CSUM;
4794+
netdev->hw_enc_features |= NETIF_F_GSO_UDP_TUNNEL |
4795+
NETIF_F_GSO_UDP_TUNNEL_CSUM;
4796+
netdev->gso_partial_features = NETIF_F_GSO_UDP_TUNNEL_CSUM;
4797+
netdev->vlan_features |= NETIF_F_GSO_UDP_TUNNEL |
4798+
NETIF_F_GSO_UDP_TUNNEL_CSUM;
47954799
}
47964800

47974801
if (mlx5e_tunnel_proto_supported_tx(mdev, IPPROTO_GRE)) {

0 commit comments

Comments
 (0)