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 915E9A0A0E for ; Mon, 10 May 2021 18:25:50 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8BD044003E; Mon, 10 May 2021 18:25:50 +0200 (CEST) Received: from NAM10-BN7-obe.outbound.protection.outlook.com (mail-bn7nam10on2066.outbound.protection.outlook.com [40.107.92.66]) by mails.dpdk.org (Postfix) with ESMTP id 602824003E for ; Mon, 10 May 2021 18:25:49 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=HkzpBkxUMCUv+a8f/xcCbpjkwpe17PtzxOVbmbnvPlphV+JdLYyITRZvmrFWVdrY5OMvaUXcLOh50qspyGNfH2MhOslo7HsKmiUSpEyS1BgBDNTG5bmZb/rBZsm8U63cgv1LhM5JLlimalIg1Dsf4IAEReTkH4CORCryLJ8noQJ5uH8+SOfjo4ffQ3ZzmWiUnFKaALlla2qTM83QEzumxkEpT/5dX5HWDofsPNDxn2E4JLAKNXwy2iShfk0oA+Hbk26AGP86ZgTYkxxFCUiwD4gegNts1PQ2Gmqt7ckGP8eBOxGHXdOueTPqeWSH1CJ/aUyicAXqnRNv5+G3Hx6G5Q== 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=dznVCuJqpxcLqV1IY3gSMWTNIaEdqQavrlG5kR7gJ0c=; b=iuVYJr2GNIdrEAKxK7DHljifjHUt1UrwRtMTL8SzIW7rLmGrP3kfYRs+7GhaaLXlEvvnFJEaKHFZBOZuVuG+UNIsTJUeCbyV1kWSC+NRM8h5DupmoR8FRujl5vxPbJ1qvPPLGwldXY+3EPjiOogE1ntiUgMaUuERMWHzPgaEsUxiCBVIdy2D1BgGIEfAIJnxTQly4fmjqnzfZ4aFeq+so5C9AYnFXTrxq39h2EVlW9HTWz6gBki9vq8IFoFTkXdDq6MG0FYGLbAXGuP44y+ZMcdC+QNSDyTv9N1PB8wwzCnLWYLK9A7A4PK8pmwut/JCUibDE8OrcicZD12Mf8tRgQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.112.34) smtp.rcpttodomain=intel.com 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=dznVCuJqpxcLqV1IY3gSMWTNIaEdqQavrlG5kR7gJ0c=; b=r0MTwJXq1dD6YVsSZei4jUTendz29saIS6c8YyCKP+rtlr3P7+XwEKLwcPgwB4qflZ6KrjcoG4QS0Pe8d0GwVVMi2TDy9m6l47qVDzu+FmDgFB+x8oF6fE+N2CX/5b+IRNLvYq/NBXJndGcEvEZlw5s4r0A10sL1upVBzPGkaxDb5Hwjha4zS7+It5pUmOZNdS8jro4b2po5CLiVPr+1PrkIOQ8aWXle3qwP0CTtSlIzoUxfnQIfImvfm3/rt3IQT6xf+B1+FAKL1n8fK95ve2C5KkU1oX9C326dS7YhPzcDnn3cUDEwsnunpmPmUtDxpN0+JHzC7BlqmC5JYeDX4Q== Received: from BN7PR06CA0058.namprd06.prod.outlook.com (2603:10b6:408:34::35) by SJ0PR12MB5469.namprd12.prod.outlook.com (2603:10b6:a03:37f::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4108.26; Mon, 10 May 2021 16:25:47 +0000 Received: from BN8NAM11FT004.eop-nam11.prod.protection.outlook.com (2603:10b6:408:34:cafe::83) by BN7PR06CA0058.outlook.office365.com (2603:10b6:408:34::35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4108.25 via Frontend Transport; Mon, 10 May 2021 16:25:47 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.112.34) smtp.mailfrom=nvidia.com; intel.com; dkim=none (message not signed) header.d=none;intel.com; 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 BN8NAM11FT004.mail.protection.outlook.com (10.13.176.164) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.4108.25 via Frontend Transport; Mon, 10 May 2021 16:25:47 +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; Mon, 10 May 2021 16:25:45 +0000 From: Xueming Li To: Murphy Yang CC: Luca Boccassi , Beilei Xing , dpdk stable Date: Tue, 11 May 2021 00:02:56 +0800 Message-ID: <20210510160258.30982-227-xuemingl@nvidia.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210510160258.30982-1-xuemingl@nvidia.com> References: <20210510160258.30982-1-xuemingl@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [172.20.145.6] X-ClientProxiedBy: HQMAIL111.nvidia.com (172.20.187.18) To HQMAIL107.nvidia.com (172.20.187.13) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 5b40c967-f437-4559-51d9-08d913d044af X-MS-TrafficTypeDiagnostic: SJ0PR12MB5469: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:9508; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 6NyLdUR+tgbJdZOT4XaYdSqU8Ab3t/hRzq9JP+oEBDKbVz6uefF9FLBvhYrc69ALK1t8YGVj9H3l+RoS4RSUeffnwqmzvvi5XMFKIEThSRy9TFist2RkkdHjvDwNU3xDlDTSvTNEjzy4VAYS5f9CL0+TnhOOxS7ao+qP5OLtwG7nQp0hhpZCz/F58YppysxoBRfAYiEum+AUMrJJz1Sfo3Br0MoGtUrG2BjE2xsa0hJXSXOgTfFCSq0byt2kTkFEC1ss37nTsKxznUoun1xmKr4f6zlUCAgJlyDhxfVo8j1P34ISZ5UvmzWmN9ysoCUyN2ltERnDr7rDnebrm5l59KKPabbFqSI1wI4HLpC7+8O4mkas32DLp85sfRofxrShTF9wxSVscjr4Z3Y8+r4Wa0WnX/aj6XyczD4Jgv573lMPXsZkpMfEcpXM476PVUQATrE+sytL42etkx6YsqOkPWiP5wFB6a/MAvfhy0tXiXut4kzIZWhtAgzDrp9Zgp8Y43tUPnixiYavm/QHYH2LpirMba5V1ll4QG+RNWbzrsihZUJGEnf9M9oPfQBAAtt5CVl3aP2p/RX49bGXLd1XYIKVDZm20OGX4TiFcHNw6OfsecJeFPJurxFbUWHoDRYeaHZyr2YzjzzhvnfFu47DfnFXwYlq03Ck9U2BOEla07HcENxhmtdDBmwHQsBKehYYLdPpClhGgIzhoDQ3m0AfIIb94f8GA3X0ffNc1n3dGrxiFC50hIwXflTmDnV4Myp4gbVkzXULLHNw3H0wJmjrGA== 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)(376002)(396003)(136003)(39860400002)(46966006)(36840700001)(966005)(54906003)(2906002)(83380400001)(478600001)(55016002)(6666004)(82310400003)(16526019)(36860700001)(1076003)(5660300002)(7636003)(47076005)(36756003)(6286002)(4326008)(8676002)(356005)(26005)(7696005)(2616005)(8936002)(70206006)(316002)(70586007)(336012)(186003)(6916009)(36906005)(82740400003)(53546011)(426003)(86362001); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 May 2021 16:25:47.4192 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 5b40c967-f437-4559-51d9-08d913d044af 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: BN8NAM11FT004.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ0PR12MB5469 Subject: [dpdk-stable] patch 'net/i40e: fix flow director for common pctypes' has been queued to stable release 20.11.2 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" Hi, FYI, your patch has been queued to stable release 20.11.2 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 05/12/21. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/steevenlee/dpdk This queued commit can be viewed at: https://github.com/steevenlee/dpdk/commit/bd0291a99ab98cac01cae57de79e3dcdbd7500a0 Thanks. Xueming Li --- >From bd0291a99ab98cac01cae57de79e3dcdbd7500a0 Mon Sep 17 00:00:00 2001 From: Murphy Yang Date: Wed, 21 Apr 2021 03:44:03 +0000 Subject: [PATCH] net/i40e: fix flow director for common pctypes Cc: Luca Boccassi [ upstream commit ff04964ea6d5feeaedf421504e63e58407ffcd10 ] Currently, FDIR doesn't work for all common PCTYPEs, the root cause is that input set is not configured. Fixes: 4a072ad43442 ("net/i40e: fix flow director config after flow validate") Signed-off-by: Murphy Yang Acked-by: Beilei Xing --- drivers/net/i40e/i40e_fdir.c | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/drivers/net/i40e/i40e_fdir.c b/drivers/net/i40e/i40e_fdir.c index 37d988d21c..c9cd1e4960 100644 --- a/drivers/net/i40e/i40e_fdir.c +++ b/drivers/net/i40e/i40e_fdir.c @@ -1607,8 +1607,10 @@ i40e_flow_set_fdir_inset(struct i40e_pf *pf, /* Check if the configuration is conflicted */ if (pf->fdir.inset_flag[pctype] && - memcmp(&pf->fdir.input_set[pctype], &input_set, sizeof(uint64_t))) - return -1; + memcmp(&pf->fdir.input_set[pctype], &input_set, sizeof(uint64_t))) { + PMD_DRV_LOG(ERR, "Conflict with the first rule's input set."); + return -EINVAL; + } if (pf->fdir.inset_flag[pctype] && !memcmp(&pf->fdir.input_set[pctype], &input_set, sizeof(uint64_t))) @@ -1616,8 +1618,10 @@ i40e_flow_set_fdir_inset(struct i40e_pf *pf, num = i40e_generate_inset_mask_reg(hw, input_set, mask_reg, I40E_INSET_MASK_NUM_REG); - if (num < 0) + if (num < 0) { + PMD_DRV_LOG(ERR, "Invalid pattern mask."); return -EINVAL; + } if (pf->support_multi_driver) { for (i = 0; i < num; i++) @@ -1762,18 +1766,15 @@ i40e_flow_add_del_fdir_filter(struct rte_eth_dev *dev, i40e_fdir_filter_convert(filter, &check_filter); if (add) { - if (filter->input.flow_ext.is_flex_flow) { + /* configure the input set for common PCTYPEs*/ + if (!filter->input.flow_ext.customized_pctype) { ret = i40e_flow_set_fdir_inset(pf, pctype, filter->input.flow_ext.input_set); - if (ret == -1) { - PMD_DRV_LOG(ERR, "Conflict with the" - " first rule's input set."); - return -EINVAL; - } else if (ret == -EINVAL) { - PMD_DRV_LOG(ERR, "Invalid pattern mask."); - return -EINVAL; - } + if (ret < 0) + return ret; + } + if (filter->input.flow_ext.is_flex_flow) { for (i = 0; i < filter->input.flow_ext.raw_id; i++) { layer_idx = filter->input.flow_ext.layer_idx; field_idx = layer_idx * I40E_MAX_FLXPLD_FIED + i; -- 2.25.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2021-05-10 23:59:32.437250500 +0800 +++ 0228-net-i40e-fix-flow-director-for-common-pctypes.patch 2021-05-10 23:59:26.710000000 +0800 @@ -1 +1 @@ -From ff04964ea6d5feeaedf421504e63e58407ffcd10 Mon Sep 17 00:00:00 2001 +From bd0291a99ab98cac01cae57de79e3dcdbd7500a0 Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Luca Boccassi + +[ upstream commit ff04964ea6d5feeaedf421504e63e58407ffcd10 ] @@ -10 +12,0 @@ -Cc: stable@dpdk.org @@ -19 +21 @@ -index 22e6e34640..ac0e09bfdd 100644 +index 37d988d21c..c9cd1e4960 100644 @@ -22 +24 @@ -@@ -1608,8 +1608,10 @@ i40e_flow_set_fdir_inset(struct i40e_pf *pf, +@@ -1607,8 +1607,10 @@ i40e_flow_set_fdir_inset(struct i40e_pf *pf, @@ -35 +37 @@ -@@ -1617,8 +1619,10 @@ i40e_flow_set_fdir_inset(struct i40e_pf *pf, +@@ -1616,8 +1618,10 @@ i40e_flow_set_fdir_inset(struct i40e_pf *pf, @@ -47 +49 @@ -@@ -1763,18 +1767,15 @@ i40e_flow_add_del_fdir_filter(struct rte_eth_dev *dev, +@@ -1762,18 +1766,15 @@ i40e_flow_add_del_fdir_filter(struct rte_eth_dev *dev,