Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp3642352pxb; Mon, 24 Jan 2022 14:13:29 -0800 (PST) X-Google-Smtp-Source: ABdhPJx8r+hFAVsnphqAF0fgOQkMsE2rPE7PWVenu8XcSMsFTybVexsftJz/7qtgo3PoczgFPRml X-Received: by 2002:a17:902:ced2:b0:14b:528d:375a with SMTP id d18-20020a170902ced200b0014b528d375amr6146331plg.106.1643062408927; Mon, 24 Jan 2022 14:13:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643062408; cv=none; d=google.com; s=arc-20160816; b=zjIGmojnfu7MNigRPfYWr/Mh6FeijrhRxHBdUJDeZJGMaBXa8Byq/ZWIeT/d11Cr+1 8tnEH23h2oJh2NSgVJVUBU4x7Va13gGexko4o26ZJf4rK+Jyl4O4MjNJGtp/0OUsuTVX gGNaqMbWq2ErOORYuB1w+IJzuPsrxw3+YekOhbr31YxoNqY+uH+4J0pCOCqv4JeAMI/C ku0zVshOe+PCJlI8E9W838CvtCM6AF7n+BbtcvBRHP01Z7dB1Wd8mOGN74ETgQgk6TXO DyVC11foMi5e2eFrKie/+K3DuslGaeZTm2lMcgq980HtB7iVyiWhaBG1mFmDRvlO5Q8B 3L9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=OBhOZlSZ11oriT6JqambO/jvZ0RKAGSgrVGp/1v+f78=; b=1JcVnjzf6X9dYWxYPpuwdlqXR1dFK6Uf/u9KWkA+Vsh62xsLOI+lKqj6NX08iGkKne 9yDzMjNM+oNVeKSr51MivdBOduSFc/0Ay+wKMBM6E3pA4xTkZd34JF05lB+WOHO0qZTC XJSAiuzJY47sDq2IMT43+YWmZXpzOdyyUSPbZ/kwzEFrgoFLKb0xI0LXqXLuJLsaExyn Oh9suDmzP+ZHE6ZmNxzNp+IubhBt9ytASiS/G3kHrnn0k7AX+yfDO3xPvF2jJVAw4Fhb BsSHwc9gOT4RRp2YrGcbUQZEasaKehxTxdW6+Lhn/kw4gaqOeF1ceA0VspzMeoEZiJQy dNgw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=WCELllb+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bg10si12839358plb.504.2022.01.24.14.13.14; Mon, 24 Jan 2022 14:13:28 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=WCELllb+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1577536AbiAXWA0 (ORCPT + 99 others); Mon, 24 Jan 2022 17:00:26 -0500 Received: from dfw.source.kernel.org ([139.178.84.217]:38218 "EHLO dfw.source.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1449256AbiAXVPJ (ORCPT ); Mon, 24 Jan 2022 16:15:09 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 0ADD561451; Mon, 24 Jan 2022 21:15:09 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B8F3EC340E5; Mon, 24 Jan 2022 21:15:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1643058908; bh=d6R36MrvRchoiac2EDIDDPVYsSqO0GHpTgvcUZB/b70=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=WCELllb+ympGW39y/wUa1ruvBXBLG9A8/3AfyPhHRBJ3J8DHGdreCtUYfIM3UmZOD 1zC1LZ0iPzxe5rUXjCe6vLjiQCVHnTVv5EwE10gsNKKHKdWXUTnvgRd5b4CuLUeNyW VSpkoeUGpY0TQUq8BNwA4DSwM2Kzd2ruBkkxyAPg= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Aya Levin , Gal Pressman , Saeed Mahameed , Sasha Levin Subject: [PATCH 5.16 0409/1039] Revert "net/mlx5e: Block offload of outer header csum for UDP tunnels" Date: Mon, 24 Jan 2022 19:36:38 +0100 Message-Id: <20220124184139.064960266@linuxfoundation.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220124184125.121143506@linuxfoundation.org> References: <20220124184125.121143506@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Aya Levin [ Upstream commit 64050cdad0983ad8060e33c3f4b5aee2366bcebd ] This reverts commit 6d6727dddc7f93fcc155cb8d0c49c29ae0e71122. 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: 6d6727dddc7f ("net/mlx5e: Block offload of outer header csum for UDP tunnels") Signed-off-by: Aya Levin Reviewed-by: Gal Pressman Signed-off-by: Saeed Mahameed Signed-off-by: Sasha Levin --- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_main.c b/drivers/net/ethernet/mellanox/mlx5/core/en_main.c index 41379844eee1f..de8acd3217c18 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/en_main.c +++ b/drivers/net/ethernet/mellanox/mlx5/core/en_main.c @@ -4789,9 +4789,13 @@ static void mlx5e_build_nic_netdev(struct net_device *netdev) } if (mlx5_vxlan_allowed(mdev->vxlan) || mlx5_geneve_tx_allowed(mdev)) { - netdev->hw_features |= NETIF_F_GSO_UDP_TUNNEL; - netdev->hw_enc_features |= NETIF_F_GSO_UDP_TUNNEL; - netdev->vlan_features |= NETIF_F_GSO_UDP_TUNNEL; + netdev->hw_features |= NETIF_F_GSO_UDP_TUNNEL | + NETIF_F_GSO_UDP_TUNNEL_CSUM; + netdev->hw_enc_features |= NETIF_F_GSO_UDP_TUNNEL | + NETIF_F_GSO_UDP_TUNNEL_CSUM; + netdev->gso_partial_features = NETIF_F_GSO_UDP_TUNNEL_CSUM; + netdev->vlan_features |= NETIF_F_GSO_UDP_TUNNEL | + NETIF_F_GSO_UDP_TUNNEL_CSUM; } if (mlx5e_tunnel_proto_supported_tx(mdev, IPPROTO_GRE)) { -- 2.34.1