Message ID | 20240918134623.8441-8-viacheslavo@nvidia.com (mailing list archive) |
---|---|
State | Awaiting Upstream |
Delegated to: | Raslan Darawsheh |
Headers |
Return-Path: <dev-bounces@dpdk.org> X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 1320D459CC; Wed, 18 Sep 2024 15:48:12 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id E46634325C; Wed, 18 Sep 2024 15:47:19 +0200 (CEST) Received: from NAM11-BN8-obe.outbound.protection.outlook.com (mail-bn8nam11on2048.outbound.protection.outlook.com [40.107.236.48]) by mails.dpdk.org (Postfix) with ESMTP id 7B1E94324F; Wed, 18 Sep 2024 15:47:18 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=JflxooOZfF11TbNuwKkLzG/jMQGnWsCcVWHijTTjTFrM8m3UW1vN+BDuzrINTOI6lmFLuye/sCP724RPLM4xEjlV6roaB0bUWb/l1DXTolC8Ob7rA35QlCMr7Fjva1y7MoJcPrDhAoEthh1dUgF2Q++m9DDNZn+gFw/BCRHtZ/SWPdO4glakmkBhPrUBuKAOFvoPY/oaJqDDTVX3Pb9gBlr01g29Ce7e+K5eXDBhf6nAK/tfDPE9znH4+4VACoudam0nldFdQu4YePDyf0UPm4Ah8N4yPuCyakBdMa4uXC5q1/N3m5RNnU1FqejDe6P2FDkehtHTL6U3ZVn/2tYCSQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=dSsNBnKYkKCoBROO028dZkQvwzmgQl3UZhzatTPRrn4=; b=RuV7ba3v7xUaoNgj7tCSy2AVEDJwSwd74HX/D6o7rs9gtTjX7gMp9PHiG9PyCmAPsjeqQ0ftlgYhO30PCkqQzxcBnit9S+4v76edYKji9RRdMT9AE6KiraM5E6CmO10hRHziRkTzXnvPbGnoB0t7kXjfZ4xK0HrTswPKbPPs8oORyM6oQy33psdjCm2nmcnUt8ZM4xfTC0dUnfeeEkqah87nirT2jAPKN130/JeHRFtBu3Oh4yRuEzgdHHyk4xt0kx4Hu2O/6lrzg6arDKND3zZePNfGfwuIggMiwYZg8wS8EkcLWlEmJ4TeQUrv/Z9cOpwTsQ70VUITpZY2Jd2x1g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.161) smtp.rcpttodomain=dpdk.org smtp.mailfrom=nvidia.com; dmarc=pass (p=reject sp=reject pct=100) action=none header.from=nvidia.com; dkim=none (message not signed); arc=none (0) 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=dSsNBnKYkKCoBROO028dZkQvwzmgQl3UZhzatTPRrn4=; b=igNPd6UY30vvXZTkCmIYpR8BtMoHxqBx85tx8QkWmDCZEIuAbG3jcTEI9ojWj8uVzFID5qV56p+QDeTsXUhAx1XqzP19VptobGoQKmKBahHXRWfZVYd2BUaVC3RMzApBtOxJHD+HP9J+uKLEvmtCuJqi/fCD2LafzDqmFcxvPd+pu3BJbBv9ENwkxprsReNoYtoE5qu59d5mF/2hzuvQp3A8VZZXdzqwQiCTSOJDKtXc+2N6fbOiiR5c7jwEK4P5GARnZPv/1dM6doebIbiCPTt7BmdidYrTpxXweEz7+Vtqmqzp03FN4OT1usgRhD51NaGnU3fPEJR1KP86/qfATA== Received: from CH0PR03CA0345.namprd03.prod.outlook.com (2603:10b6:610:11a::29) by CY8PR12MB9033.namprd12.prod.outlook.com (2603:10b6:930:71::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7962.24; Wed, 18 Sep 2024 13:47:15 +0000 Received: from DS2PEPF00003441.namprd04.prod.outlook.com (2603:10b6:610:11a:cafe::c1) by CH0PR03CA0345.outlook.office365.com (2603:10b6:610:11a::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7962.25 via Frontend Transport; Wed, 18 Sep 2024 13:47:15 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.117.161) smtp.mailfrom=nvidia.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 216.228.117.161 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.117.161; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (216.228.117.161) by DS2PEPF00003441.mail.protection.outlook.com (10.167.17.68) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7918.13 via Frontend Transport; Wed, 18 Sep 2024 13:47:15 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by mail.nvidia.com (10.129.200.67) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.4; Wed, 18 Sep 2024 06:47:03 -0700 Received: from nvidia.com (10.126.230.35) by rnnvmail201.nvidia.com (10.129.68.8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.4; Wed, 18 Sep 2024 06:47:01 -0700 From: Viacheslav Ovsiienko <viacheslavo@nvidia.com> To: <dev@dpdk.org> CC: <matan@nvidia.com>, <rasland@nvidia.com>, <orika@nvidia.com>, <dsosnowski@nvidia.com>, <stable@dpdk.org> Subject: [PATCH v2 7/9] net/mlx5: fix next protocol validation after flex item Date: Wed, 18 Sep 2024 16:46:21 +0300 Message-ID: <20240918134623.8441-8-viacheslavo@nvidia.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240918134623.8441-1-viacheslavo@nvidia.com> References: <20240911160458.524732-1-viacheslavo@nvidia.com> <20240918134623.8441-1-viacheslavo@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.230.35] X-ClientProxiedBy: rnnvmail203.nvidia.com (10.129.68.9) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DS2PEPF00003441:EE_|CY8PR12MB9033:EE_ X-MS-Office365-Filtering-Correlation-Id: afad83be-e4ba-4520-551e-08dcd7e867f6 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|36860700013|1800799024|82310400026|376014; X-Microsoft-Antispam-Message-Info: jq8MP8a/07GWNe+VGubIezUzGL4j7X8iXjYgqnZ/GSVQIx2+LHpwCgjzgqRh6n8X5ORlnObj1tWDwhjymk2VZrb5fEsullA2Q+fMFSDryFtNImZZLgBUMVlWT/5OQyVol/ITv7YEdw+/atF0J/XEsE02K75jYpC38nYmw1ngiAB6pUkduQqmThd83z75pot8pGA9sHZN06xgraJecNull9+KoBdm3mljoTcnX0sqStVjZgtCKSjjaHQWnT1pUWfOhZWPrRdvacsljZy9DNfDsBo1DAHmbRuKLEcVS/dyT0hlIRSLnsAJwixng9G9+6ouVT9Nc7edhHGKrwx06C4rlaDzNX7zSGjpM1DVy87xyXw7p/xJ8mveX3kdTfDe/MjrzUvhMHWbKh0nJ8FDe8FMplcjRs0iSWw9I6xw1ZgXo/Pzvhat6hJ3QA16tlqnLQZXpJ6tKH2nWuk4qo414NoYxsTusfMcGgLjfMZw2NfUVLauQNTlApIfIO9Hsf6AYJSvWlCxhcH4Zmzs/kDuSztCFtknwOgQvMJTV4+F3mUlErqBzo2GazSE+rU3cjXioPMjqTEuuV4zu7WZZYUBHynSHiiJAODCi9DL5iRS2hQBXa/I4dILzr5r3As36Z9TXrhIxUXAVC1Y9DJJLEPur/zazZ7tPqEIwOrDCGSYpN9/HDWj+eiyExwB95HtAqs3MT7qF1bHECaeJaDd/Qwurhw3mKgtutcjzcTZVNcxGYjLOS0wEv51pxYC/0++6OAn5m0SjvJmdakxcnF5GaSNMxXDqNyBRZVnVfIg3XRRI7fdOaQ1hLQJBl9J0biFbkgTexEJARFsoDmFd0N5woG72KLolYvGLRxoYVxdRm6uWI334rS7crWGN2y4XcrJlBd11B8Ub2Figs8ZzztUc3z9nA/bT2Oud59MOxVM+3CGc39eWKWhdwDci8wRVgwBqmbBftkRoQFdCLtkWWz/dzKcyZ4UwFgpSIkUEL6huCucmBi0SXfUtbeUjx4PacQ3qlBZPfJgIwtaJuK6VcJF1umrKFiAoXwlrrH2Vre9Pc6gAdrx3+XV8/kUlD/ZdHn6mBIrE+PchWUAdC0yQHuEdjijmbNH8z643+CoKyJ2FTvBXdC/Fz1D/ByB2V065GoT5wFQMARdbt8PvFCQ+rnf6+9+IpkWWUgc1yPhvM+VhNh0HB7yx7Ls3qoNp7vEalODOoVgVihxc+e3hGfwINGq/RxByoW2seJl108JCjk52VIwhR7RoYwI+SCj9EVVZTQlziIVXnjoKrYvfZjcYnoCxJgR/G+HPQIlctXwTmtgPdfI2kvhSdXRtJhC9UyjUg4F/MUq+QF0mlfUZqjW9izA+FriYRL803X6ePVtkgi1gFDzizjfCUeF0VCpr3n9952xwmDLmVKnR5VokZ5aB9pu8L4R99MMmiQP07/4SJGM39d9CeFDRRIi2HUXwmPA7qxahTYUpObW X-Forefront-Antispam-Report: CIP:216.228.117.161; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:dc6edge2.nvidia.com; CAT:NONE; SFS:(13230040)(36860700013)(1800799024)(82310400026)(376014); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Sep 2024 13:47:15.4786 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: afad83be-e4ba-4520-551e-08dcd7e867f6 X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.117.161]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: DS2PEPF00003441.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY8PR12MB9033 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions <dev.dpdk.org> List-Unsubscribe: <https://mails.dpdk.org/options/dev>, <mailto:dev-request@dpdk.org?subject=unsubscribe> List-Archive: <http://mails.dpdk.org/archives/dev/> List-Post: <mailto:dev@dpdk.org> List-Help: <mailto:dev-request@dpdk.org?subject=help> List-Subscribe: <https://mails.dpdk.org/listinfo/dev>, <mailto:dev-request@dpdk.org?subject=subscribe> Errors-To: dev-bounces@dpdk.org |
Series |
net/mlx5: cumulative fix series for flex item
|
|
Checks
Context | Check | Description |
---|---|---|
ci/checkpatch | success | coding style OK |
Commit Message
Viacheslav Ovsiienko
Sept. 18, 2024, 1:46 p.m. UTC
On the flow validation some items may check the preceding protocols.
In case of flex item the next protocol is opaque (or can be multiple
ones) we should set neutral value and allow successful validation,
for example, for the combination of flex and following ESP items.
Fixes: a23e9b6e3ee9 ("net/mlx5: handle flex item in flows")
Cc: stable@dpdk.org
Signed-off-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
---
drivers/net/mlx5/mlx5_flow_dv.c | 2 ++
1 file changed, 2 insertions(+)
Comments
> -----Original Message----- > From: Slava Ovsiienko <viacheslavo@nvidia.com> > Sent: Wednesday, September 18, 2024 15:46 > To: dev@dpdk.org > Cc: Matan Azrad <matan@nvidia.com>; Raslan Darawsheh > <rasland@nvidia.com>; Ori Kam <orika@nvidia.com>; Dariusz Sosnowski > <dsosnowski@nvidia.com>; stable@dpdk.org > Subject: [PATCH v2 7/9] net/mlx5: fix next protocol validation after flex item > > On the flow validation some items may check the preceding protocols. > In case of flex item the next protocol is opaque (or can be multiple > ones) we should set neutral value and allow successful validation, for example, > for the combination of flex and following ESP items. > > Fixes: a23e9b6e3ee9 ("net/mlx5: handle flex item in flows") > Cc: stable@dpdk.org > > Signed-off-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com> > --- > drivers/net/mlx5/mlx5_flow_dv.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c > index a51d4dd1a4..b18bb430d7 100644 > --- a/drivers/net/mlx5/mlx5_flow_dv.c > +++ b/drivers/net/mlx5/mlx5_flow_dv.c > @@ -8196,6 +8196,8 @@ flow_dv_validate(struct rte_eth_dev *dev, const > struct rte_flow_attr *attr, > tunnel != 0, > error); > if (ret < 0) > return ret; > + /* Reset for next proto, it is unknown. */ > + next_protocol = 0xff; > break; > case RTE_FLOW_ITEM_TYPE_METER_COLOR: > ret = flow_dv_validate_item_meter_color(dev, items, > -- > 2.34.1 Acked-by: Dariusz Sosnowski <dsosnowski@nvidia.com> Resending the Ack for each patch separately, because patchwork assigned my Ack for the series to v1, not v2. Best regards, Dariusz Sosnowski
diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c index a51d4dd1a4..b18bb430d7 100644 --- a/drivers/net/mlx5/mlx5_flow_dv.c +++ b/drivers/net/mlx5/mlx5_flow_dv.c @@ -8196,6 +8196,8 @@ flow_dv_validate(struct rte_eth_dev *dev, const struct rte_flow_attr *attr, tunnel != 0, error); if (ret < 0) return ret; + /* Reset for next proto, it is unknown. */ + next_protocol = 0xff; break; case RTE_FLOW_ITEM_TYPE_METER_COLOR: ret = flow_dv_validate_item_meter_color(dev, items,