From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id ADA01A0569; Thu, 12 Mar 2020 10:24:53 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id B17261C020; Thu, 12 Mar 2020 10:24:52 +0100 (CET) Received: from EUR04-VI1-obe.outbound.protection.outlook.com (mail-eopbgr80043.outbound.protection.outlook.com [40.107.8.43]) by dpdk.org (Postfix) with ESMTP id 04C351C01B; Thu, 12 Mar 2020 10:24:51 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=iCO0NLUZHKjmbHO/SQN8DNLTAxEalDhtPcNnWkUKF7ZJgNhvqzjqLk2MhdsaqkB/PfmFjwepMBa/PuigB8TCiti5h04LDtKT2yIJsunOg9MmalS/5Asm0auUwAZc6Ab31r9BpG53SKRkk/lRcpCn7WM3GZBDkwr8M3fv3okfF7SDb/LteNcRPTv/15PAWM88CNeoLJ9cEnLsjca3Tsg2pcJZup8W0CrCpOnf8FhS8Le+j468gl04Rkp7FX54ZnO0rH9GofHRV90kjJpsyRA8/CQicF38yBL1HfkJFsGFK5e3R3lFNGmlbAuMFRYlSVIszHd1+4U+U0VlW+4RwZIs3A== 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=sKd/IGEj/TuSiWnjgzPkKMBtkNZWxKhQtiB0NldOcVo=; b=XNOuX3VexJ7xlA3RNbxSBwOQGR0muCCRQzSqsfWVyBO57XWMyik0qze+fNKs6a5eKzgIZvsDSj8Uxfz6EPe5oIrfD1GB3BumUOBhfnAYqjp0jXJJ41S5WgJL9VhMAB8BquACR7viALNvzgnc8MgJY+LJOFrx9joIKk2UL4bdst11BlUl2Cxfa0Fp5iW2LCVRmqC+CXT4qhnuNpBLohya7gqE4Y8VcCpjnVL7l9u0LE043/pzZtnUndGRRijRsyfMGaDG3u2Xuw2wUO7D3q12t+IuvZUNwu+gWGI3cmpKRzRjC5UKG2Oa2C7kplHL5eIPgAjk1dr97314CPLG0/rBhg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=mellanox.com; dmarc=pass action=none header.from=mellanox.com; dkim=pass header.d=mellanox.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Mellanox.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=sKd/IGEj/TuSiWnjgzPkKMBtkNZWxKhQtiB0NldOcVo=; b=YlyigSrBAU8TC2pj04Qf5M0Ppg3pt0cob5OPTONj5pysPGvU20KRIKIUr5qSjvTYOGjRBkhA5TzesXGVtMlqgbZHBLTruWKzH2B+bVBg4RIUgFRgSB5H/1zfnbMlo9+BouZLXWwC/ao799rK7pZVMbhoZCELN1qwA2xfa85VZh4= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=wisamm@mellanox.com; Received: from AM0PR05MB6610.eurprd05.prod.outlook.com (20.178.202.18) by AM0PR05MB6770.eurprd05.prod.outlook.com (10.186.175.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2793.16; Thu, 12 Mar 2020 09:24:50 +0000 Received: from AM0PR05MB6610.eurprd05.prod.outlook.com ([fe80::f9b0:5b27:21a3:c758]) by AM0PR05MB6610.eurprd05.prod.outlook.com ([fe80::f9b0:5b27:21a3:c758%3]) with mapi id 15.20.2793.018; Thu, 12 Mar 2020 09:24:50 +0000 From: Wisam Jaddo To: dev@dpdk.org, rasland@mellanox.com, matan@mellanox.com Cc: viacheslavo@mellanox.com, stable@dpdk.org Date: Thu, 12 Mar 2020 11:24:40 +0200 Message-Id: <1584005080-32321-1-git-send-email-wisamm@mellanox.com> X-Mailer: git-send-email 2.7.4 Content-Type: text/plain X-ClientProxiedBy: PR3P191CA0019.EURP191.PROD.OUTLOOK.COM (2603:10a6:102:54::24) To AM0PR05MB6610.eurprd05.prod.outlook.com (2603:10a6:208:12f::18) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from mellanox.com (37.142.13.130) by PR3P191CA0019.EURP191.PROD.OUTLOOK.COM (2603:10a6:102:54::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.2793.16 via Frontend Transport; Thu, 12 Mar 2020 09:24:49 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [37.142.13.130] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 50530f52-e10b-4239-e724-08d7c66736a4 X-MS-TrafficTypeDiagnostic: AM0PR05MB6770:|AM0PR05MB6770: X-LD-Processed: a652971c-7d2e-4d9b-a6a4-d149256f461b,ExtFwd X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:5236; X-Forefront-PRVS: 0340850FCD X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4636009)(39860400002)(396003)(346002)(376002)(136003)(366004)(199004)(26005)(8886007)(2906002)(6636002)(4326008)(450100002)(86362001)(16526019)(186003)(6666004)(36756003)(478600001)(52116002)(7696005)(66556008)(66476007)(66946007)(5660300002)(956004)(2616005)(316002)(81166006)(81156014)(55016002)(8676002)(8936002); DIR:OUT; SFP:1101; SCL:1; SRVR:AM0PR05MB6770; H:AM0PR05MB6610.eurprd05.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; Received-SPF: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: I0z7rbLKdPb4B+2CfLuRbpMvO2EaUnzWTxWZLdUokRhTY8AIWvACeeSkwfjHRGoXp0uf5/ObEhez9tgjKoGP6QIeHZPB+7z5Mtev+XgCUoiuQPnt7bDR9OohiIlnKfcufwdFrWTFxFDKuWAOZ7Ge7d2nEW37FEptBYkR4KMGcz8IYJnYPP3b9fZShtkbXK928ToYG7SV0TOcNEga1xwNn1yw8BtcuKR0OSiIouPLZtvZaIeEZ0hgPyg2kqBklHIF63X4Ah7VP7A2TUA0c6eTRraUwuoGEsECmS+GSIxfSPwcYaYios8aqqbGMiMaFU7g0VgEwTgWtfInxat3UePl6bfLtxBqS31fUtW96zhuLRFdpvlgKgbiwN8JZWwzWUCP/qBSygT/bkzPW9MLktr/w6ld7R5zfs1eucyQIG899emSEdyH+v7qJaou3Y75FnN0 X-MS-Exchange-AntiSpam-MessageData: jl4G7lSUBKL43HCIwFCXgB91eZ1n8Bup1YuUxhnfNkvXNGA0h7EBGRQfhZIRLt1MrV/fe0UCUqKRpeEu9VbxjvYgb9OkfOC5xA/tX7CNqAfiUCFh3dh5+iAyJ1Qh0XYYWJEpaoUaLzgj6woHjCpGrA== X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-Network-Message-Id: 50530f52-e10b-4239-e724-08d7c66736a4 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 Mar 2020 09:24:49.9600 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Zi/2QRqMCTeVK3s63Mlrkr0fQ0c2Z/ESuyl2PtINT18IjK9j5WpyQtCCK2uBis5ztDa988Rb/xV9/gZQhzPpqg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR05MB6770 Subject: [dpdk-dev] [PATCH] net/mlx5: fix validate set meta action for zero value X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" There is no reason to prevent the user from using zero metadata, it indeed means no metadata, but sometimes the user may need to report to datapath that there is no metadata anymore, which is valid case. Fixes: fcc8d2f716fd ("net/mlx5: extend flow metadata support") Cc: viacheslavo@mellanox.com Cc: stable@dpdk.org Signed-off-by: Wisam Jaddo Acked-by: Viacheslav Ovsiienko --- drivers/net/mlx5/mlx5_flow_dv.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c index e7278f0..e2d6690 100644 --- a/drivers/net/mlx5/mlx5_flow_dv.c +++ b/drivers/net/mlx5/mlx5_flow_dv.c @@ -2109,10 +2109,6 @@ flow_dv_validate_action_set_meta(struct rte_eth_dev *dev, return rte_flow_error_set(error, EINVAL, RTE_FLOW_ERROR_TYPE_ACTION, action, "meta data must be within reg C0"); - if (!(conf->data & conf->mask)) - return rte_flow_error_set(error, EINVAL, - RTE_FLOW_ERROR_TYPE_ACTION, action, - "zero value has no effect"); return 0; } -- 2.7.4