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 DFD9643AFD; Sun, 18 Feb 2024 06:12:44 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8B63840F1A; Sun, 18 Feb 2024 06:12:20 +0100 (CET) Received: from NAM04-BN8-obe.outbound.protection.outlook.com (mail-bn8nam04on2062.outbound.protection.outlook.com [40.107.100.62]) by mails.dpdk.org (Postfix) with ESMTP id EFB3240F1A for ; Sun, 18 Feb 2024 06:12:18 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=oGbRj7k+peN0flseVwML89u4LEKVOXcs33UMeW76AqjlQkw7xYPZILE7Hbw6WZQFT/bwK6Z26Df+AsxBj7is1Q1+1kEm/ubBwIXtJQVeMVHbd4Yi7ZPWOmgH0XlFEWzyW931K5zUkl3uxiu3QA10R4asBVd/4XnnrZOw39vGghG5CMsQDEw6Bm7rSmGW5YWufgKiD5QVsGcCJzZSFekrHeno49aT/AtCNO++93+D0X2mn2Wd0aX7FsRxtzvL8AhRJ2OCOapwmluYnUWoG2vYppPHDZ6/7HQzu1JCbYJg0uNlPP3ega/m1VAhdJ7xUDaJQPjxDQvk3ugpWHhBX4d53A== 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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=LBslI7knY85sqF7mprdQZRd5utpuknqU4scH30NkDOc=; b=A9PBgvdkUh4vKIAmi0tjxf0HlfX392EM4r+XrWEPAOcQjSDR1MVBjyUAXsv2VuvuyHpTG8O1bw/aOp4WVoA+AePAO8gwd230cR+s174pM4PeUjgh+SSadcGmtRKXGwQA8B+T1HGLuep1U78Ot9BL8TxUvIApizEDS1+pf27VOAlGkBp32aEishxVJGhU03XZ9uviiqmLmSC/2JfFDD8IcpyebBHcE+k9VyYzbwEiNbEKuK2VFNih+LzBdAS6sT0O5oIXP9FYnh2/g8EVcmdEDCf717OOuSeB9stvFJ6wCLUSbTzivc2rTnpSuYFfLqyy7bFFvnBHi9YZo9eGWmYMCA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.118.233) smtp.rcpttodomain=monjalon.net 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=LBslI7knY85sqF7mprdQZRd5utpuknqU4scH30NkDOc=; b=DdzS6cD0blokRRCskvW/xXK8DMfs3q06Mx7RBjkOQujlgg/HFVq+jQKjP6tGymwODzA8xjpO2k99Jiq3cNL9R2NTgwTSKJlbw8plSwRjetks1H5vGkSrUmI75RiNPW4ycwgZ6Pb0xL+enyaBYZJ3VmP4mdnrsdGeDbFv4igvDuH2D6qpPaGcGk4T1sWk/oalAsfLcj9juXpxjYqykidmnNQhE0wpUMieX2xPVlqp9N1pAef8k33YL5bMBFOuQ3m+XPBxoTaae7jDOGcmeGfJFNjs78xHo2z9IgeZhmSvboPR81vKiUlJQlhuslXVJtITkoG1Rh75mdelL4pFX9+L3A== Received: from CH0PR03CA0200.namprd03.prod.outlook.com (2603:10b6:610:e4::25) by DM4PR12MB8560.namprd12.prod.outlook.com (2603:10b6:8:189::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7316.17; Sun, 18 Feb 2024 05:12:16 +0000 Received: from CH3PEPF0000000A.namprd04.prod.outlook.com (2603:10b6:610:e4:cafe::d7) by CH0PR03CA0200.outlook.office365.com (2603:10b6:610:e4::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7292.32 via Frontend Transport; Sun, 18 Feb 2024 05:12:16 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.118.233) 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.118.233 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.118.233; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (216.228.118.233) by CH3PEPF0000000A.mail.protection.outlook.com (10.167.244.37) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7292.25 via Frontend Transport; Sun, 18 Feb 2024 05:12:16 +0000 Received: from drhqmail202.nvidia.com (10.126.190.181) by mail.nvidia.com (10.127.129.6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.41; Sat, 17 Feb 2024 21:12:05 -0800 Received: from drhqmail202.nvidia.com (10.126.190.181) by drhqmail202.nvidia.com (10.126.190.181) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1258.12; Sat, 17 Feb 2024 21:12:05 -0800 Received: from nvidia.com (10.127.8.12) by mail.nvidia.com (10.126.190.181) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1258.12 via Frontend Transport; Sat, 17 Feb 2024 21:12:02 -0800 From: Itamar Gozlan To: , , , , , , , Dariusz Sosnowski , Ori Kam , Matan Azrad CC: Subject: [v2 08/10] net/mlx5/hws: add missing actions STE limitation Date: Sun, 18 Feb 2024 07:11:22 +0200 Message-ID: <20240218051125.717011-8-igozlan@nvidia.com> X-Mailer: git-send-email 2.39.3 In-Reply-To: <20240218051125.717011-1-igozlan@nvidia.com> References: <20240213095038.451299-9-igozlan@nvidia.com> <20240218051125.717011-1-igozlan@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-NV-OnPremToCloud: ExternallySecured X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CH3PEPF0000000A:EE_|DM4PR12MB8560:EE_ X-MS-Office365-Filtering-Correlation-Id: 99a98bcd-77e1-46e7-9d59-08dc30402c82 X-LD-Processed: 43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 2/tqyNF8ZeiVTehfIAU09yj3Eb2Z9BJhNZRQdXl6sPrH8hEK8b7jlzqFiFGQg5hUB4DXIF81ovbXXHrvGxwrCPMVXb0G+6EWvpB9noJZBGecKYud28ErFhXDKG/3i/N3AP/iYuWS9Y/DZNbd7bwHcYzLSktb7BosbIfn6kL3gzHKLQ41J5sZz0DcqdWFaKyigcPIcZvt75QOMzuavvu5x0BZKxp9b2Eqr3iARQRCLIoAsgHpgV078uX5AP5ruIvPTKWv92se+vRYYD++fuHyGZMJgrplp7ZgRwAql/3AQoEBzRXxekS0nNibV0DdOnnQhmpqJTT3FZfWR5MkdERIO5l43xY7rIYP+LSSe4o2R51fboJI4SC1KMyDZVztLQEbPWPL/3luRuWZ3AVOPiAaSAnRrc+sEI9VJL9YWQHY6l2x//nsLRFB2JbCspfkPq3K1lOoPWLZcp8v6FY91AfNKpfic9ZxPrNh5giWFLIjNru6bq1LHZcHkOjrepBEsHicPyIASdbND6XEej68X5r5UGGvtQs2Slvshx3VAxr8+kPyJ3Duoy8syzAaD4VzRaAFIX8Yi9V6IC+TM5VzuC9ko3bSiWuttxYU0Hs45DTU90YQ2FF9cZC5PTt7VUxN1WHmBEVTPwR02A1O6NMv14e7+DzsNqs1tocQPXP7/o5SpmQ= X-Forefront-Antispam-Report: CIP:216.228.118.233; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:dc7edge2.nvidia.com; CAT:NONE; SFS:(13230031)(4636009)(39860400002)(376002)(396003)(346002)(136003)(230922051799003)(1800799012)(64100799003)(451199024)(82310400011)(186009)(36860700004)(40470700004)(46966006)(2906002)(8936002)(4326008)(8676002)(5660300002)(426003)(336012)(83380400001)(2616005)(921011)(26005)(1076003)(36756003)(86362001)(356005)(7636003)(82740400003)(6636002)(110136005)(70586007)(70206006)(316002)(7696005)(6286002)(6666004)(478600001)(55016003)(41300700001); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Feb 2024 05:12:16.1159 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 99a98bcd-77e1-46e7-9d59-08dc30402c82 X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.118.233]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: CH3PEPF0000000A.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM4PR12MB8560 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org From: Hamdan Igbaria Today if we pass a remove header action and after it an insert header action then our action template builder will set two different STE setters, because it won't allow insert header in same STE as remove header. But if we have the opposite order of insert header and then remove header actions, then the setter will set both of them on the same STE since the opposite check was missing. This patch added the missing opposite limitation. Signed-off-by: Hamdan Igbaria Acked-by: Matan Azrad --- drivers/net/mlx5/hws/mlx5dr_action.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/mlx5/hws/mlx5dr_action.c b/drivers/net/mlx5/hws/mlx5dr_action.c index 370886907f..8589de5557 100644 --- a/drivers/net/mlx5/hws/mlx5dr_action.c +++ b/drivers/net/mlx5/hws/mlx5dr_action.c @@ -3308,7 +3308,8 @@ int mlx5dr_action_template_process(struct mlx5dr_action_template *at) case MLX5DR_ACTION_TYP_REMOVE_HEADER: case MLX5DR_ACTION_TYP_REFORMAT_TNL_L2_TO_L2: /* Single remove header to header */ - setter = mlx5dr_action_setter_find_first(last_setter, ASF_SINGLE1 | ASF_MODIFY); + setter = mlx5dr_action_setter_find_first(last_setter, + ASF_SINGLE1 | ASF_MODIFY | ASF_INSERT); setter->flags |= ASF_SINGLE1 | ASF_REMOVE; setter->set_single = &mlx5dr_action_setter_single; setter->idx_single = i; -- 2.39.3