From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id A5D91A0C44 for ; Wed, 12 May 2021 12:24:30 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 9255F410E3; Wed, 12 May 2021 12:24:30 +0200 (CEST) Received: from NAM11-DM6-obe.outbound.protection.outlook.com (mail-dm6nam11on2058.outbound.protection.outlook.com [40.107.223.58]) by mails.dpdk.org (Postfix) with ESMTP id 83E004003E; Wed, 12 May 2021 12:24:28 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=czmG/zowRfodewDf7DWkoL8l62qwEntV/S2Ry6vAh64sfFH9DkaPQ8RH+TSoh2uYNQh3BT9XIgXwX1ztcY0geZdv7pLP/EwX497dPRvOskwUqbOxu48hFNhXUK6HoiKlxMu4AA+juaO5Ic9+X4tQQw46h8GXwOedoB0x78QUjL8Puf+70VADelAFizey8vu8q/3GPDHBq2xtESEC4atPzBnSk37pgV25J/x9rSHfFtmjnw5xezzTe8ROJ/if18rTnYAdAGh+wj99awjBcYoscaR3cOmPIc6IGcG9t/Jt4W2UqOtQ3+NTjtC8SpvsQJSE2lZhPfoHCZP2xcC+VYC8wQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=e/yrgfnsj25a3+vQ5383wqcTabB5NcDw99e5Hf1gvKQ=; b=FK7nQRb6GCr1wlx5fjNzlLo/XkApLHN1q7ZOGPIRx8ybsHHqGM3pZooYMgTrMBn4+o+mZnCmtYrz6Tdlh43WBoz9+LwvWojaX6lBnb008gd9UFwvvaVQZT9v5uc2hOqf9fhjhj6ea/Lp8UE+N3E/A13ZkN9yAGARSw+MCQHaHGY+ybl0p36q4RcEgkvnNNybT8JaWEmo0JmLm/FpcYZAdf6WdvtKPqb4qSiKiAv70KrsTEHPZ4EQlgDD3zvVJTPVQd+1A4XjAx5ulWgM7q8kBA8rc7oY8okuc5D3NdU08aLlcEn3ararJPspJkQYHjogyG7t9W+FOZDdqAUOvShK5w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.112.34) smtp.rcpttodomain=dpdk.org smtp.mailfrom=nvidia.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=nvidia.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=e/yrgfnsj25a3+vQ5383wqcTabB5NcDw99e5Hf1gvKQ=; b=YiJUREwyM9odb5dxgn42g+46hv06qmEZ9GxE/Yd5mYETOsTonixlzans0xRow7XN/YA+bm0rV6bWT0N9exvKlP3VEiDawNohgaV0M8SdQgQN7RS0SnQ6ojs5Vujazz2yR7oEqSLi1qEZRhaGkngxQZGgSjqWhjkWDhv4EV5EdTVNLOo7Uf5WPl2j9QXm7JoESEUwp/0gDCLceCQYKld/ECANfcllgJR0wB2B2N28e2F5BlIamEQ5yaY1D+CZuLApDcDRXxho25xKLewNw4hsmzwiVGXvkZhhqgXxX2KsGMW5NFgDJI7EXg9PqcdBXVcLwEWrJrpE0aBr3YSc5/nMvA== Received: from DM5PR15CA0060.namprd15.prod.outlook.com (2603:10b6:3:ae::22) by DM6PR12MB3628.namprd12.prod.outlook.com (2603:10b6:5:3d::26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4129.25; Wed, 12 May 2021 10:24:26 +0000 Received: from DM6NAM11FT023.eop-nam11.prod.protection.outlook.com (2603:10b6:3:ae:cafe::64) by DM5PR15CA0060.outlook.office365.com (2603:10b6:3:ae::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4108.25 via Frontend Transport; Wed, 12 May 2021 10:24:26 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.112.34) smtp.mailfrom=nvidia.com; dpdk.org; dkim=none (message not signed) header.d=none;dpdk.org; dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 216.228.112.34 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.112.34; helo=mail.nvidia.com; Received: from mail.nvidia.com (216.228.112.34) by DM6NAM11FT023.mail.protection.outlook.com (10.13.173.96) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.4129.25 via Frontend Transport; Wed, 12 May 2021 10:24:26 +0000 Received: from nvidia.com (172.20.145.6) by HQMAIL107.nvidia.com (172.20.187.13) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Wed, 12 May 2021 10:24:23 +0000 From: Jiawei Wang To: , , , , , Shahaf Shuler , Xiaoyu Min , Dekel Peled CC: , , Date: Wed, 12 May 2021 13:24:08 +0300 Message-ID: <20210512102408.7501-1-jiaweiw@nvidia.com> X-Mailer: git-send-email 2.18.1 In-Reply-To: <20210512064231.16648-1-jiaweiw@nvidia.com> References: <20210512064231.16648-1-jiaweiw@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [172.20.145.6] X-ClientProxiedBy: HQMAIL107.nvidia.com (172.20.187.13) To HQMAIL107.nvidia.com (172.20.187.13) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: a633d187-e9a6-45a8-f0b8-08d915301e83 X-MS-TrafficTypeDiagnostic: DM6PR12MB3628: X-LD-Processed: 43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1227; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Upljlz3B9ID+UBO3sYTk/5bZZSAF5jGWxGCNmMmMMOfMbFpNI4xNvQUwtN+XP2q/JxwQ3dH6itsfm3Selpn5J6kex6tFNleg/v430u8ftxNpuc/yXahpoBMMsZd8BCsSrepPWvUGNWhyZxDEfPMCz+mo1aM44VxLjuKSge7WfyjadNbRYN6T9z1HT1JxsbYPpeNCXDWcbBIz6foZUsnkTVw4nDg8oZZjwOxg4RJY4bzpU8qu2/wF4PQoxSTf0CyALg+l7kyt7cenHREv70fHmqeVYJdhAu/aPDy52xzRmq07wyNUfcWgpWaunPmMVR9cxs81TSLgu1Z4hQrn6JH+3QZwXOA+oIsvQLJ/FwbS7KHtFXMfQtSf7I6pSZD7l5l/JHpOwpiYAlX6dXw6yOMo9ENirBjHPib+RysvIGiSk1qnNIdJL9uXyz+ksYLkcolUP7eGT6ToWo8AMwBBCzDucrxziaiV+KNqO7Y/crEtJgoviJ4UboYIYY1JDktv0Mkw1EDOQZXZ6aeK9WXLJbSNGeNStdFkTBQ2BkNIdPkq0G/dWEEHj7GXOWVUmNDFMd8FIdtlv14B+Wt+4SakMRtN1ALscKnkB25g8uD88/Bd4SC3oM0k+bdu5vGn7fpeycM2uuJgPYmFEc+25TumaMEHxw== X-Forefront-Antispam-Report: CIP:216.228.112.34; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:schybrid03.nvidia.com; CAT:NONE; SFS:(4636009)(346002)(136003)(396003)(39860400002)(376002)(46966006)(36840700001)(316002)(36906005)(83380400001)(110136005)(6666004)(54906003)(1076003)(6286002)(55016002)(356005)(7636003)(86362001)(82740400003)(82310400003)(36756003)(26005)(478600001)(336012)(426003)(2616005)(2906002)(186003)(16526019)(36860700001)(5660300002)(7696005)(8676002)(8936002)(70206006)(70586007)(4326008)(47076005); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 May 2021 10:24:26.3043 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: a633d187-e9a6-45a8-f0b8-08d915301e83 X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.112.34]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: DM6NAM11FT023.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB3628 Subject: [dpdk-stable] [PATCH v2] net/mlx5: fix RSS expansion for NVGRE X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" Currently RSS expansion only supports GRE and GRE KEY. This patch adds RSS expansion for NVGRE item so PMD can expand flow item correctly. Fixes: ea81c1b816f7 ("net/mlx5: fix NVGRE matching") Cc: stable@dpdk.org Signed-off-by: Jiawei Wang Acked-by: Xiaoyu Min --- drivers/net/mlx5/mlx5_flow.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c index 32634c9af7..73cc9acbd7 100644 --- a/drivers/net/mlx5/mlx5_flow.c +++ b/drivers/net/mlx5/mlx5_flow.c @@ -407,6 +407,7 @@ enum mlx5_expansion { MLX5_EXPANSION_VXLAN, MLX5_EXPANSION_VXLAN_GPE, MLX5_EXPANSION_GRE, + MLX5_EXPANSION_NVGRE, MLX5_EXPANSION_GRE_KEY, MLX5_EXPANSION_MPLS, MLX5_EXPANSION_ETH, @@ -465,6 +466,7 @@ static const struct mlx5_flow_expand_node mlx5_support_expansion[] = { (MLX5_EXPANSION_OUTER_IPV4_UDP, MLX5_EXPANSION_OUTER_IPV4_TCP, MLX5_EXPANSION_GRE, + MLX5_EXPANSION_NVGRE, MLX5_EXPANSION_IPV4, MLX5_EXPANSION_IPV6), .type = RTE_FLOW_ITEM_TYPE_IPV4, @@ -487,7 +489,8 @@ static const struct mlx5_flow_expand_node mlx5_support_expansion[] = { MLX5_EXPANSION_OUTER_IPV6_TCP, MLX5_EXPANSION_IPV4, MLX5_EXPANSION_IPV6, - MLX5_EXPANSION_GRE), + MLX5_EXPANSION_GRE, + MLX5_EXPANSION_NVGRE), .type = RTE_FLOW_ITEM_TYPE_IPV6, .rss_types = ETH_RSS_IPV6 | ETH_RSS_FRAG_IPV6 | ETH_RSS_NONFRAG_IPV6_OTHER, @@ -526,6 +529,10 @@ static const struct mlx5_flow_expand_node mlx5_support_expansion[] = { .type = RTE_FLOW_ITEM_TYPE_GRE_KEY, .optional = 1, }, + [MLX5_EXPANSION_NVGRE] = { + .next = MLX5_FLOW_EXPAND_RSS_NEXT(MLX5_EXPANSION_ETH), + .type = RTE_FLOW_ITEM_TYPE_NVGRE, + }, [MLX5_EXPANSION_MPLS] = { .next = MLX5_FLOW_EXPAND_RSS_NEXT(MLX5_EXPANSION_IPV4, MLX5_EXPANSION_IPV6), -- 2.18.1