From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR02-HE1-obe.outbound.protection.outlook.com (mail-eopbgr10055.outbound.protection.outlook.com [40.107.1.55]) by dpdk.org (Postfix) with ESMTP id AE68F2BBD; Mon, 4 Jun 2018 19:37:49 +0200 (CEST) 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=Aq+gA4+4I4CnUBjcb2PT3IbMYDSUPTC5Z9We6mv/Hac=; b=cDUpKHW6NVtnO+SfeCyhOtKf/qMm2kglsx/sISz/SvFrOpDsymy2PiUxkv9UTp6YkkFpsZKha3A/7UtS9UELyX6/FNn6ICT4dffx7ZRxhmOKpP9ra5IFeykNZ9/GwFUU7enoat7uWx32IEQc6IpoUMi1/YXCaKDWYb3C+FMbFTM= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=yskoh@mellanox.com; Received: from mellanox.com (209.116.155.178) by DB6PR0501MB2039.eurprd05.prod.outlook.com (2603:10a6:4:6::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.820.11; Mon, 4 Jun 2018 17:37:46 +0000 From: Yongseok Koh To: adrien.mazarguil@6wind.com, nelio.laranjeiro@6wind.com Cc: dev@dpdk.org, shahafs@mellanox.com, Yongseok Koh , stable@dpdk.org Date: Mon, 4 Jun 2018 10:37:31 -0700 Message-Id: <20180604173731.29125-1-yskoh@mellanox.com> X-Mailer: git-send-email 2.11.0 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [209.116.155.178] X-ClientProxiedBy: BYAPR02CA0029.namprd02.prod.outlook.com (2603:10b6:a02:ee::42) To DB6PR0501MB2039.eurprd05.prod.outlook.com (2603:10a6:4:6::21) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(48565401081)(5600026)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060)(7193020); SRVR:DB6PR0501MB2039; X-Microsoft-Exchange-Diagnostics: 1; DB6PR0501MB2039; 3:U5aC7fkfp5uFoE8HCTz994Zirxq0R9X4EKF7iRE0kowhZ+LbT5I9OiOlP0F/XwH4bTmhXa9ScU5oW/TDOaOkbdi+TFyNSACg5TBSk1+zOWsmEFbvG9cZXHb6OfSvf1mHSYqLrTpvfxlBhP/MsC4ursRtZ7d4IvW8VhBU7T0d2+sJqgiAKTzmSHLMU7/ga/rxNpUM8/6VUg5n87v1+VLccWfABldrbFrCSQLVI8MTrd0vzhsqq9aQisqKNDlLQyKc; 25:MjokFhcEoqAkZcQYAzS8c3Zm6ssdzxmwhdzqNYqsFvi5Dokr9sdY0BdrNYN0x/PVC9S8QfbdqYIzuuFANk/QeSOyr1POoyIMArhH/MpyoHIKGiE4ZbY3TQrbcoRNodHSyf3F49f9lFtwTqwzOSp6VtKTau1gSnFJKGeK6ZKuVZ0YyN5b73IFa+gRexx+q9ttVleIspF7otagxeXZbMGg20fRDmo4Vju18UXjE79AlXtoRQwbiI984V5FAdOttJpkxjTY9Qszp5dYA2COHgMa3+x9KYzJ0Sq7TlG7hcMohY4NgxiILf2p23L4qVX58KC9DLmt6xqrLmpLKSkShAS3fw==; 31:TSYlRkxU5GIIyK8LMWSOPbqUH8TGAM0k/lYWPnpdyeXgCGgKBzL7V/ygtnjLygBE/QY0BO2Rq/Iw1T+3l4YhOABdwQ1fYcSvwAhIx1kF4S1lWzn3/Y6Vl+lkfsaXOaaF+avpLinFEt+WO8DMb1KuGTp7ldOABNdsCIrzYqCNFhuDV5UoFUrNimEsH0AivXfKG/0haH4TBTD8TQFNHYhfqvBg2y/5avY/NRBR09eFp2M= X-MS-TrafficTypeDiagnostic: DB6PR0501MB2039: X-LD-Processed: a652971c-7d2e-4d9b-a6a4-d149256f461b,ExtAddr X-Microsoft-Exchange-Diagnostics: 1; DB6PR0501MB2039; 20:S8DyI61Eo8XTOQe/tY+QoAN/v8Pj+D9FBernSI5F1yEKIy84+trAkQDIFcm9HyIuMLXDPtJSohcQZ7il0gRL5mk9Fx5m80Br4+RyYf/WRdYr0HPtMEV+kUsFBgqzb7DBAa/hjKn8H8vza/mHkThehkNRQ9m0cbPCUSmWezkrX67a5hABU3MKZCChNf5HULByKxtZXfR1z0zRbml01af82VwyzdKjEHYszRbonM6FDHy0/9Z+lo/AXk0bRZMUwTPgmmEjaabDa75qva/e2h2squrhGEa+vgBlqYM4LISEd3Mlv2VqHcDmStnINOk+vME/7PPc3IAArpvCdWevJvdtQoubYDnxTe868erRXg2DbVuss/OmHedNTSHpETDTuLwsSiFHtF4lQ+PlM4geUUeg8f2Jcj3d3U36VJyTHcVD9o6HwFkkjjj+Fqh/wfdlwc/FGzX8y3IbcPqk7kt6daZKJfqqMSSg6FnjGFQ2WyaKmyZqTdg7JLxTWWroNq7sSbY3; 4:1dwv97bPr7hE+7ycyBWhDSQl+oXMe/hWLRiszBc1TTP1LxnvebBxFTkP4egqGOZMALXXy31ETsyGTRWR2wTsda4i0Bj3sXscr3khUWmu/jCwi0w85OGUyMWnBsytJDjCy+7188edmAKvDuRosRdgBfqcgd6tqFjp2XjTPJeQnB6+uTJa5ABNFlP0T+sEkl4GEyoEELslnSS5XTlibkGfRkkaNObkXCZ2sfIyXKfEE4Y2eUQsGmfTqTGHmChtM5OzBNPxxRFDYt8RvOJIyAb6/g== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(93006095)(93001095)(10201501046)(3002001)(3231254)(944501410)(52105095)(6055026)(149027)(150027)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123562045)(20161123558120)(20161123564045)(6072148)(201708071742011)(7699016); SRVR:DB6PR0501MB2039; BCL:0; PCL:0; RULEID:; SRVR:DB6PR0501MB2039; X-Forefront-PRVS: 069373DFB6 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(979002)(346002)(396003)(39860400002)(376002)(39380400002)(366004)(189003)(199004)(66066001)(305945005)(51416003)(52116002)(476003)(956004)(50466002)(81166006)(316002)(16586007)(2616005)(1076002)(478600001)(21086003)(8936002)(106356001)(7736002)(26005)(1857600001)(386003)(7696005)(59450400001)(3846002)(6116002)(486006)(105586002)(25786009)(53936002)(36756003)(55016002)(16526019)(86362001)(186003)(6666003)(47776003)(4326008)(48376002)(50226002)(8676002)(81156014)(68736007)(69596002)(5660300001)(2906002)(97736004)(969003)(989001)(999001)(1009001)(1019001); DIR:OUT; SFP:1101; SCL:1; SRVR:DB6PR0501MB2039; H:mellanox.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; Received-SPF: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DB6PR0501MB2039; 23:d7P4moWT8G0VgfXH1G1qZrC2xZ9cRd6ZAdv43iD?= =?us-ascii?Q?TRyMcdiR/M5KqIj/XkAry71iGPjzeOQG4EytIlo+2WPSKs4zVCafsnvXF5rJ?= =?us-ascii?Q?wKnFc8DRlMAmqi1LB3CA6mVf+dSYA6gdiQX+iMmWtQ2TrWrFyBcsnWX8NeCn?= =?us-ascii?Q?DbeCHSK8Pey+6WmpIWhxb6BjPP2f5v0SkK3um107Pfq6TDQmDIMP/1uupm6E?= =?us-ascii?Q?vkXfxvhlKQdDF8Rrrd7yYW31AyQ4YfqnUtoDeT7u4QTtQJXxCTDCt+UkulAG?= =?us-ascii?Q?b8zIsxm9vjG6aaSleIwmvtacqdUxjCHEqdaZCL6Nt6ACNhPxBB8dWFsMWLZW?= =?us-ascii?Q?3GJttUvaHOdGLNGfxTPDj6pjw1TY+3t79QUuX4funqaxFpjENMAQyFW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 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; DB6PR0501MB2039; 7:0Os9GuCannBOEzvpwQ10tUHwFrp19sCKTKwZlv+uR7ys98nLLJso60CwFp/3AA8eb8NjYSHDrn7bfDa3TfCBRAuCBJUsTGIicpZTWmtmooDZdEF2PalJuscmm8U2kp3+yNmVt8Y6Oh86Q1g90+7dequPy34l1QY2XSeuq25QItMI0CCEcS0HpAJklsoYAHyfEQh3JYDvOif9PbVDR+gczlvbN3Ja7SgSkk/qh+Iq61oZAvoO1iZoJMBe5XF1s2Jc X-MS-Office365-Filtering-Correlation-Id: 7b07908e-6b7c-4a39-b004-08d5ca41e2fc X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Jun 2018 17:37:46.1268 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 7b07908e-6b7c-4a39-b004-08d5ca41e2fc X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR0501MB2039 Subject: [dpdk-dev] [PATCH] net/mlx5: fix error number handling 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: , X-List-Received-Date: Mon, 04 Jun 2018 17:37:50 -0000 rte_errno should be saved only if error has occurred because rte_errno could have garbage value. Fixes: a6d83b6a9209 ("net/mlx5: standardize on negative errno values") Cc: stable@dpdk.org Signed-off-by: Yongseok Koh --- drivers/net/mlx5/mlx5_flow.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c index 994be05be..eaffe7495 100644 --- a/drivers/net/mlx5/mlx5_flow.c +++ b/drivers/net/mlx5/mlx5_flow.c @@ -3561,7 +3561,8 @@ mlx5_fdir_filter_delete(struct rte_eth_dev *dev, /* The flow does not match. */ continue; } - ret = rte_errno; /* Save rte_errno before cleanup. */ + if (ret) + ret = rte_errno; /* Save rte_errno before cleanup. */ if (flow) mlx5_flow_list_destroy(dev, &priv->flows, flow); exit: -- 2.11.0