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 67F8B45B5A; Thu, 17 Oct 2024 09:58:54 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 0E8544067D; Thu, 17 Oct 2024 09:58:30 +0200 (CEST) Received: from NAM10-DM6-obe.outbound.protection.outlook.com (mail-dm6nam10on2083.outbound.protection.outlook.com [40.107.93.83]) by mails.dpdk.org (Postfix) with ESMTP id 4657B4066E for ; Thu, 17 Oct 2024 09:58:27 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=by7O7MVGvhYjDQ6D37TOWrFRX4jU1X297mVLwuj9qXL4du7jJ2z5eZO8e4SI5COT3INS92Nq9keoy0HsqxYtgZdoLRu3oBpfq/gsTAsOkXXpJ9cy3EqCGDee2MGMLUHh8NqdQzk9f4GhMKTd26kRpgAxDD4eGrT9f3iiyLMs+AQHqLiQejBhTM36QR1udEXUSGImfjwabHdTQd2GMlkq9AdvuFU0TJiLi3ZIGEGS9lWd9bZibfdWyQe7LsK3kDGaZXT69rraxexJNavhbjThRTjYFdNMc3FNxUK7Msl2GGkv/j2MuIB9LE89Wb6bol8ewz8uWHaPA3A+PvBX5bAbWg== 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=92/ngKZ7cdg431LqnKVwXz9dx+Kj9zKN1UChimYO7+Y=; b=RWaXmzHhfuLHBxTxkbIq/k5g+kpUCL90jThDF1844Pd3pbphP99RNOfKy7Fmsxd8zgGxQ4X+PhnH81gzSELOksrQgrlcqmNqVHm4NYk/7HUXwrnwU1hWaviufy8Kodt8oyjTACdsqcBjAWLN80G/+P1w6d8Hj8jq430D0hOjWk3AXkK5cayl4Skb/UmlZUZ1Fjjm8BJju/q5UcmJyv6G7gtH/QwnA4pRdplaYRHbzDA2rE8y97PuLWkZQ5ug9XxrL2Ik1PQVQmNb8FpZk9QLdbQ0A+qF63zNbBaETMwE61z2JsPqiJ+8FGX3QbgNB3XJU1z7qwHUuJR0sSI/dFeU5Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.160) 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=92/ngKZ7cdg431LqnKVwXz9dx+Kj9zKN1UChimYO7+Y=; b=hWNrwdI789oJtARXwdj+3TKgqHkZWoqOEt+A7kikbX3krNdIYBUsImze+g5lw25OuuOmnTnxyJHCI2NVpivKXsfAdHXZ9Ztc3xELsxuBl44bM9nhIEyCqB7xc6K70H1w56RebI7vJXKnYob4i3ER4IWFEPrPlaHAprVmyx3vzob5XwZw33JuDzYTrlO8uULpVSoTRyyRc96NL+dnpv/TJRgSrUazXDfra1lI9eBXPiHQCHrNtP0NOpTApYd7CAEevxzy2W9SYlJVh1mdHFxb+tiXc3RfPT3/MHME/bf5P7zDQyAt6XzTg3qI588lAOFMob8CS26xDDqvNSeVn+lP5Q== Received: from SN4PR0501CA0123.namprd05.prod.outlook.com (2603:10b6:803:42::40) by LV8PR12MB9270.namprd12.prod.outlook.com (2603:10b6:408:205::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8048.26; Thu, 17 Oct 2024 07:58:24 +0000 Received: from SA2PEPF000015C7.namprd03.prod.outlook.com (2603:10b6:803:42:cafe::6c) by SN4PR0501CA0123.outlook.office365.com (2603:10b6:803:42::40) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8069.16 via Frontend Transport; Thu, 17 Oct 2024 07:58:23 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.117.160) 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.160 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.117.160; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (216.228.117.160) by SA2PEPF000015C7.mail.protection.outlook.com (10.167.241.197) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8069.17 via Frontend Transport; Thu, 17 Oct 2024 07:58:23 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by mail.nvidia.com (10.129.200.66) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.4; Thu, 17 Oct 2024 00:58:10 -0700 Received: from nvidia.com (10.126.231.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; Thu, 17 Oct 2024 00:58:08 -0700 From: Dariusz Sosnowski To: Viacheslav Ovsiienko , Bing Zhao , Ori Kam , Suanming Mou , Matan Azrad CC: Subject: [PATCH 05/10] net/mlx5: rename control flow rules types Date: Thu, 17 Oct 2024 09:57:33 +0200 Message-ID: <20241017075738.190064-6-dsosnowski@nvidia.com> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241017075738.190064-1-dsosnowski@nvidia.com> References: <20241017075738.190064-1-dsosnowski@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.231.35] X-ClientProxiedBy: rnnvmail201.nvidia.com (10.129.68.8) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SA2PEPF000015C7:EE_|LV8PR12MB9270:EE_ X-MS-Office365-Filtering-Correlation-Id: 3e54591a-de11-4dac-525a-08dcee8179b2 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|82310400026|376014|36860700013|1800799024; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?A6vULqFvQk5jaegAbJ/8uOmjQ/YoDIe5OcjrXHsEcfEVuAsHw4Ubchri7I8k?= =?us-ascii?Q?zsCtY3ZqOK4oezIlfqhkHVOwNh8FPykWMxXY7FWBoIb5Q+w/4VvwQWwkOYLQ?= =?us-ascii?Q?CiWtWppk/xBy8kNAGyWDo+lQTGqjG3W85KM7q8mf3HNkAZUrMOgTlO5zeWSl?= =?us-ascii?Q?/VS8leFyoH+udj41qTUOvOGDkNFB/1UOz7FtHJLtO5Ud+e0lmfoXgoXYRWjO?= =?us-ascii?Q?PVMd3E8jgT4J3OZal/INctzdsIo+Nz5bbItzHJVlJi9MwL57gCVKQ1QXjiT4?= =?us-ascii?Q?yLSQmibu16fwbvHoivcBsg7yuAszzzb/WjJtYv6TxhyGA7FGHNkJtdelw3E0?= =?us-ascii?Q?pZfZPIQglU6aPlDbJ4CwmpDAzAjarZ20urB+WrG/Mid06C7Z8sxiOaayOhhs?= =?us-ascii?Q?ejdviQjSUVYcNaHQrzIkL9lHtcMuwPwZGQq7KWr+1IiG8LXtnX3KY8NF+IGf?= =?us-ascii?Q?/cIabesG6HF3lL/YuacjZ4unNjFH8FJiKsLaQWotW7iS9LaRR+d58fgCBZ1j?= =?us-ascii?Q?QtoKmuKEiVgH3eDuVvHuRljhvxIw66f0BSICfyuMMdU+SJTwHaJ25mzmbxI1?= =?us-ascii?Q?GuzKJg5Ur1eejV67m0WnrXdXtV6fOGwtZd3P/AeYr8z3I9evx5Wxe1rIy7bP?= =?us-ascii?Q?Outb3LZqfjDcx3LZXfY1DF6bqad+Cu6mY0qqOsKmey+Gx1aRPtlGohsO78CB?= =?us-ascii?Q?PW8WvqeMZ3TxF/4VFcRUMgCA64SXxuaz3N3ew85rF+M3uGIyhR6lKK87ziAv?= =?us-ascii?Q?7pkOGT3c/w7e2H0GX3flcwOh1jWQ0zzB1EkmvWMhkO/ckZf6/qJplz+UhvZx?= =?us-ascii?Q?NRMRsPmzN081MJi0pEWuhyqNjmQxA7O0xq4VP5x8xgfAipm42HFrgqDFhs9K?= =?us-ascii?Q?VBO8cCUWiFhXVwh2kJxEki47VUpAgZngsiQ7e8pp00MqwE0en3ainWWLbmw7?= =?us-ascii?Q?Jk1NnCvf/RnReXl8pCTDAM+v89sgQoPi2R+88q45k2MBGGquoJB2Mjy8szzC?= =?us-ascii?Q?un5uYrXi+m3y8Zy2CqZrkFdD+bHbes++2yqSqE6Sx4J1lQk0T+A201hWj4r9?= =?us-ascii?Q?cJ4IVjc8eBPz6edcJ16YgmzS4OluSCfOi1BLqRHOCf1KDfKMvx59C+yks3PY?= =?us-ascii?Q?KyHV4Ctzf4LJ1Y21nB5o3aP5bo0lr3pG6Cj4vDUz+Oc4QyzXH0wPaSaCbsR2?= =?us-ascii?Q?w5WLZ1oiHLWqRg1dLLGaL4IQZNBaK+TrPHCDmGXtfeNQVMTbXfoAQ71RVEUh?= =?us-ascii?Q?6xxAQvvtD/r2tYEJam/hXflEkzS4piX9W5TmAoIpvfFm9clG0cIbiAOrhFMO?= =?us-ascii?Q?4ioEsI3s/g1nhUZoJ4d/loDU2t5ROUL+u9m2v9AFam706gi8BBi0WFmAQsFA?= =?us-ascii?Q?j5yZelH7ar5BoGjmoBZlgDVktTJ6QbaZxYnm0+a03thTrF/aUA=3D=3D?= X-Forefront-Antispam-Report: CIP:216.228.117.160; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:dc6edge1.nvidia.com; CAT:NONE; SFS:(13230040)(82310400026)(376014)(36860700013)(1800799024); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 Oct 2024 07:58:23.8283 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 3e54591a-de11-4dac-525a-08dcee8179b2 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.160]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: SA2PEPF000015C7.namprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: LV8PR12MB9270 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 All structs and enumerations used for managenement of HWS control flow rules do not really depend on HWS itself. In order to allow their reuse with Verbs and DV flow engines and allow fine-grained creation/destruction of unicast DMAC (with VLAN) flow rules with these flow engines, this patch renames all related structs and enumerations. All are renamed as follows: - Enum mlx5_hw_ctrl_flow_type renamed to mlx5_ctrl_flow_type. - Enum prefix MLX5_HW_CTRL_FLOW_TYPE_ changes to MLX5_CTRL_FLOW_TYPE_ - Struct mlx5_hw_ctrl_flow_info renamed to mlx5_ctrl_flow_info. - Struct mlx5_hw_ctrl_flow renamed to mlx5_ctrl_flow_entry. Signed-off-by: Dariusz Sosnowski --- drivers/net/mlx5/mlx5.h | 36 ++++++++-------- drivers/net/mlx5/mlx5_flow.c | 8 ++-- drivers/net/mlx5/mlx5_flow_hw.c | 74 ++++++++++++++++----------------- 3 files changed, 59 insertions(+), 59 deletions(-) diff --git a/drivers/net/mlx5/mlx5.h b/drivers/net/mlx5/mlx5.h index 3551b793d6..a51727526f 100644 --- a/drivers/net/mlx5/mlx5.h +++ b/drivers/net/mlx5/mlx5.h @@ -1787,23 +1787,23 @@ struct mlx5_obj_ops { #define MLX5_RSS_HASH_FIELDS_LEN RTE_DIM(mlx5_rss_hash_fields) -enum mlx5_hw_ctrl_flow_type { - MLX5_HW_CTRL_FLOW_TYPE_GENERAL, - MLX5_HW_CTRL_FLOW_TYPE_SQ_MISS_ROOT, - MLX5_HW_CTRL_FLOW_TYPE_SQ_MISS, - MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_JUMP, - MLX5_HW_CTRL_FLOW_TYPE_TX_META_COPY, - MLX5_HW_CTRL_FLOW_TYPE_TX_REPR_MATCH, - MLX5_HW_CTRL_FLOW_TYPE_LACP_RX, - MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_RX_RSS, - MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC, - MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC_VLAN, +enum mlx5_ctrl_flow_type { + MLX5_CTRL_FLOW_TYPE_GENERAL, + MLX5_CTRL_FLOW_TYPE_SQ_MISS_ROOT, + MLX5_CTRL_FLOW_TYPE_SQ_MISS, + MLX5_CTRL_FLOW_TYPE_DEFAULT_JUMP, + MLX5_CTRL_FLOW_TYPE_TX_META_COPY, + MLX5_CTRL_FLOW_TYPE_TX_REPR_MATCH, + MLX5_CTRL_FLOW_TYPE_LACP_RX, + MLX5_CTRL_FLOW_TYPE_DEFAULT_RX_RSS, + MLX5_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC, + MLX5_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC_VLAN, }; /** Additional info about control flow rule. */ -struct mlx5_hw_ctrl_flow_info { +struct mlx5_ctrl_flow_info { /** Determines the kind of control flow rule. */ - enum mlx5_hw_ctrl_flow_type type; + enum mlx5_ctrl_flow_type type; union { /** * If control flow is a SQ miss flow (root or not), @@ -1843,8 +1843,8 @@ bool mlx5_ctrl_flow_uc_dmac_vlan_exists(struct rte_eth_dev *dev, const uint16_t vid); /** Entry for tracking control flow rules in HWS. */ -struct mlx5_hw_ctrl_flow { - LIST_ENTRY(mlx5_hw_ctrl_flow) next; +struct mlx5_ctrl_flow_entry { + LIST_ENTRY(mlx5_ctrl_flow_entry) next; /** * Owner device is a port on behalf of which flow rule was created. * @@ -1856,7 +1856,7 @@ struct mlx5_hw_ctrl_flow { /** Pointer to flow rule handle. */ struct rte_flow *flow; /** Additional information about the control flow rule. */ - struct mlx5_hw_ctrl_flow_info info; + struct mlx5_ctrl_flow_info info; }; /* HW Steering port configuration passed to rte_flow_configure(). */ @@ -1965,8 +1965,8 @@ struct mlx5_priv { struct mlx5_drop drop_queue; /* Flow drop queues. */ void *root_drop_action; /* Pointer to root drop action. */ rte_spinlock_t hw_ctrl_lock; - LIST_HEAD(hw_ctrl_flow, mlx5_hw_ctrl_flow) hw_ctrl_flows; - LIST_HEAD(hw_ext_ctrl_flow, mlx5_hw_ctrl_flow) hw_ext_ctrl_flows; + LIST_HEAD(hw_ctrl_flow, mlx5_ctrl_flow_entry) hw_ctrl_flows; + LIST_HEAD(hw_ext_ctrl_flow, mlx5_ctrl_flow_entry) hw_ext_ctrl_flows; struct mlx5_flow_hw_ctrl_fdb *hw_ctrl_fdb; struct rte_flow_pattern_template *hw_tx_repr_tagging_pt; struct rte_flow_actions_template *hw_tx_repr_tagging_at; diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c index 69f8bd8d97..af79956eaa 100644 --- a/drivers/net/mlx5/mlx5_flow.c +++ b/drivers/net/mlx5/mlx5_flow.c @@ -12185,11 +12185,11 @@ bool mlx5_ctrl_flow_uc_dmac_exists(struct rte_eth_dev *dev, const struct rte_ether_addr *addr) { struct mlx5_priv *priv = dev->data->dev_private; - struct mlx5_hw_ctrl_flow *entry; + struct mlx5_ctrl_flow_entry *entry; bool exists = false; LIST_FOREACH(entry, &priv->hw_ctrl_flows, next) { - if (entry->info.type == MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC && + if (entry->info.type == MLX5_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC && rte_is_same_ether_addr(addr, &entry->info.uc.dmac)) { exists = true; break; @@ -12204,11 +12204,11 @@ mlx5_ctrl_flow_uc_dmac_vlan_exists(struct rte_eth_dev *dev, const uint16_t vid) { struct mlx5_priv *priv = dev->data->dev_private; - struct mlx5_hw_ctrl_flow *entry; + struct mlx5_ctrl_flow_entry *entry; bool exists = false; LIST_FOREACH(entry, &priv->hw_ctrl_flows, next) { - if (entry->info.type == MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC_VLAN && + if (entry->info.type == MLX5_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC_VLAN && rte_is_same_ether_addr(addr, &entry->info.uc.dmac) && vid == entry->info.uc.vlan) { exists = true; diff --git a/drivers/net/mlx5/mlx5_flow_hw.c b/drivers/net/mlx5/mlx5_flow_hw.c index 35e9eead7e..0d8224b8de 100644 --- a/drivers/net/mlx5/mlx5_flow_hw.c +++ b/drivers/net/mlx5/mlx5_flow_hw.c @@ -15086,7 +15086,7 @@ flow_hw_create_ctrl_flow(struct rte_eth_dev *owner_dev, uint8_t item_template_idx, struct rte_flow_action actions[], uint8_t action_template_idx, - struct mlx5_hw_ctrl_flow_info *info, + struct mlx5_ctrl_flow_info *info, bool external) { struct mlx5_priv *priv = proxy_dev->data->dev_private; @@ -15095,7 +15095,7 @@ flow_hw_create_ctrl_flow(struct rte_eth_dev *owner_dev, .postpone = 0, }; struct rte_flow *flow = NULL; - struct mlx5_hw_ctrl_flow *entry = NULL; + struct mlx5_ctrl_flow_entry *entry = NULL; int ret; rte_spinlock_lock(&priv->hw_ctrl_lock); @@ -15131,7 +15131,7 @@ flow_hw_create_ctrl_flow(struct rte_eth_dev *owner_dev, if (info) entry->info = *info; else - entry->info.type = MLX5_HW_CTRL_FLOW_TYPE_GENERAL; + entry->info.type = MLX5_CTRL_FLOW_TYPE_GENERAL; if (external) LIST_INSERT_HEAD(&priv->hw_ext_ctrl_flows, entry, next); else @@ -15208,8 +15208,8 @@ static int flow_hw_flush_ctrl_flows_owned_by(struct rte_eth_dev *dev, struct rte_eth_dev *owner) { struct mlx5_priv *priv = dev->data->dev_private; - struct mlx5_hw_ctrl_flow *cf; - struct mlx5_hw_ctrl_flow *cf_next; + struct mlx5_ctrl_flow_entry *cf; + struct mlx5_ctrl_flow_entry *cf_next; int ret; cf = LIST_FIRST(&priv->hw_ctrl_flows); @@ -15287,8 +15287,8 @@ static int flow_hw_flush_all_ctrl_flows(struct rte_eth_dev *dev) { struct mlx5_priv *priv = dev->data->dev_private; - struct mlx5_hw_ctrl_flow *cf; - struct mlx5_hw_ctrl_flow *cf_next; + struct mlx5_ctrl_flow_entry *cf; + struct mlx5_ctrl_flow_entry *cf_next; int ret; cf = LIST_FIRST(&priv->hw_ctrl_flows); @@ -15344,8 +15344,8 @@ mlx5_flow_hw_esw_create_sq_miss_flow(struct rte_eth_dev *dev, uint32_t sqn, bool }; struct rte_flow_item items[3] = { { 0 } }; struct rte_flow_action actions[3] = { { 0 } }; - struct mlx5_hw_ctrl_flow_info flow_info = { - .type = MLX5_HW_CTRL_FLOW_TYPE_SQ_MISS_ROOT, + struct mlx5_ctrl_flow_info flow_info = { + .type = MLX5_CTRL_FLOW_TYPE_SQ_MISS_ROOT, .esw_mgr_sq = sqn, }; struct rte_eth_dev *proxy_dev; @@ -15434,7 +15434,7 @@ mlx5_flow_hw_esw_create_sq_miss_flow(struct rte_eth_dev *dev, uint32_t sqn, bool actions[1] = (struct rte_flow_action){ .type = RTE_FLOW_ACTION_TYPE_END, }; - flow_info.type = MLX5_HW_CTRL_FLOW_TYPE_SQ_MISS; + flow_info.type = MLX5_CTRL_FLOW_TYPE_SQ_MISS; ret = flow_hw_create_ctrl_flow(dev, proxy_dev, proxy_priv->hw_ctrl_fdb->hw_esw_sq_miss_tbl, items, 0, actions, 0, &flow_info, external); @@ -15447,15 +15447,15 @@ mlx5_flow_hw_esw_create_sq_miss_flow(struct rte_eth_dev *dev, uint32_t sqn, bool } static bool -flow_hw_is_matching_sq_miss_flow(struct mlx5_hw_ctrl_flow *cf, +flow_hw_is_matching_sq_miss_flow(struct mlx5_ctrl_flow_entry *cf, struct rte_eth_dev *dev, uint32_t sqn) { if (cf->owner_dev != dev) return false; - if (cf->info.type == MLX5_HW_CTRL_FLOW_TYPE_SQ_MISS_ROOT && cf->info.esw_mgr_sq == sqn) + if (cf->info.type == MLX5_CTRL_FLOW_TYPE_SQ_MISS_ROOT && cf->info.esw_mgr_sq == sqn) return true; - if (cf->info.type == MLX5_HW_CTRL_FLOW_TYPE_SQ_MISS && cf->info.esw_mgr_sq == sqn) + if (cf->info.type == MLX5_CTRL_FLOW_TYPE_SQ_MISS && cf->info.esw_mgr_sq == sqn) return true; return false; } @@ -15467,8 +15467,8 @@ mlx5_flow_hw_esw_destroy_sq_miss_flow(struct rte_eth_dev *dev, uint32_t sqn) uint16_t proxy_port_id = dev->data->port_id; struct rte_eth_dev *proxy_dev; struct mlx5_priv *proxy_priv; - struct mlx5_hw_ctrl_flow *cf; - struct mlx5_hw_ctrl_flow *cf_next; + struct mlx5_ctrl_flow_entry *cf; + struct mlx5_ctrl_flow_entry *cf_next; int ret; ret = rte_flow_pick_transfer_proxy(port_id, &proxy_port_id, NULL); @@ -15529,8 +15529,8 @@ mlx5_flow_hw_esw_create_default_jump_flow(struct rte_eth_dev *dev) .type = RTE_FLOW_ACTION_TYPE_END, } }; - struct mlx5_hw_ctrl_flow_info flow_info = { - .type = MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_JUMP, + struct mlx5_ctrl_flow_info flow_info = { + .type = MLX5_CTRL_FLOW_TYPE_DEFAULT_JUMP, }; struct rte_eth_dev *proxy_dev; struct mlx5_priv *proxy_priv; @@ -15610,8 +15610,8 @@ mlx5_flow_hw_create_tx_default_mreg_copy_flow(struct rte_eth_dev *dev) .type = RTE_FLOW_ACTION_TYPE_END, }, }; - struct mlx5_hw_ctrl_flow_info flow_info = { - .type = MLX5_HW_CTRL_FLOW_TYPE_TX_META_COPY, + struct mlx5_ctrl_flow_info flow_info = { + .type = MLX5_CTRL_FLOW_TYPE_TX_META_COPY, }; MLX5_ASSERT(priv->master); @@ -15650,8 +15650,8 @@ mlx5_flow_hw_tx_repr_matching_flow(struct rte_eth_dev *dev, uint32_t sqn, bool e { .type = RTE_FLOW_ACTION_TYPE_END }, { .type = RTE_FLOW_ACTION_TYPE_END }, }; - struct mlx5_hw_ctrl_flow_info flow_info = { - .type = MLX5_HW_CTRL_FLOW_TYPE_TX_REPR_MATCH, + struct mlx5_ctrl_flow_info flow_info = { + .type = MLX5_CTRL_FLOW_TYPE_TX_REPR_MATCH, .tx_repr_sq = sqn, }; @@ -15708,8 +15708,8 @@ mlx5_flow_hw_lacp_rx_flow(struct rte_eth_dev *dev) .type = RTE_FLOW_ACTION_TYPE_END, }, }; - struct mlx5_hw_ctrl_flow_info flow_info = { - .type = MLX5_HW_CTRL_FLOW_TYPE_LACP_RX, + struct mlx5_ctrl_flow_info flow_info = { + .type = MLX5_CTRL_FLOW_TYPE_LACP_RX, }; if (!priv->dr_ctx || !priv->hw_ctrl_fdb || !priv->hw_ctrl_fdb->hw_lacp_rx_tbl) @@ -15831,8 +15831,8 @@ __flow_hw_ctrl_flows_single(struct rte_eth_dev *dev, { .type = RTE_FLOW_ACTION_TYPE_RSS }, { .type = RTE_FLOW_ACTION_TYPE_END }, }; - struct mlx5_hw_ctrl_flow_info flow_info = { - .type = MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_RX_RSS, + struct mlx5_ctrl_flow_info flow_info = { + .type = MLX5_CTRL_FLOW_TYPE_DEFAULT_RX_RSS, }; if (!eth_spec) @@ -15863,8 +15863,8 @@ __flow_hw_ctrl_flows_single_vlan(struct rte_eth_dev *dev, { .type = RTE_FLOW_ACTION_TYPE_RSS }, { .type = RTE_FLOW_ACTION_TYPE_END }, }; - struct mlx5_hw_ctrl_flow_info flow_info = { - .type = MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_RX_RSS, + struct mlx5_ctrl_flow_info flow_info = { + .type = MLX5_CTRL_FLOW_TYPE_DEFAULT_RX_RSS, }; unsigned int i; @@ -15909,8 +15909,8 @@ __flow_hw_ctrl_flows_unicast_create(struct rte_eth_dev *dev, { .type = RTE_FLOW_ACTION_TYPE_RSS }, { .type = RTE_FLOW_ACTION_TYPE_END }, }; - struct mlx5_hw_ctrl_flow_info flow_info = { - .type = MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC, + struct mlx5_ctrl_flow_info flow_info = { + .type = MLX5_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC, .uc = { .dmac = *addr, }, @@ -15971,8 +15971,8 @@ __flow_hw_ctrl_flows_unicast_vlan_create(struct rte_eth_dev *dev, { .type = RTE_FLOW_ACTION_TYPE_RSS }, { .type = RTE_FLOW_ACTION_TYPE_END }, }; - struct mlx5_hw_ctrl_flow_info flow_info = { - .type = MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC_VLAN, + struct mlx5_ctrl_flow_info flow_info = { + .type = MLX5_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC_VLAN, .uc = { .dmac = *addr, .vlan = vid, @@ -16216,8 +16216,8 @@ mlx5_flow_hw_ctrl_flow_dmac_destroy(struct rte_eth_dev *dev, const struct rte_ether_addr *addr) { struct mlx5_priv *priv = dev->data->dev_private; - struct mlx5_hw_ctrl_flow *entry; - struct mlx5_hw_ctrl_flow *tmp; + struct mlx5_ctrl_flow_entry *entry; + struct mlx5_ctrl_flow_entry *tmp; int ret; /* @@ -16229,7 +16229,7 @@ mlx5_flow_hw_ctrl_flow_dmac_destroy(struct rte_eth_dev *dev, while (entry != NULL) { tmp = LIST_NEXT(entry, next); - if (entry->info.type != MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC || + if (entry->info.type != MLX5_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC || !rte_is_same_ether_addr(addr, &entry->info.uc.dmac)) { entry = tmp; continue; @@ -16261,8 +16261,8 @@ mlx5_flow_hw_ctrl_flow_dmac_vlan_destroy(struct rte_eth_dev *dev, const uint16_t vlan) { struct mlx5_priv *priv = dev->data->dev_private; - struct mlx5_hw_ctrl_flow *entry; - struct mlx5_hw_ctrl_flow *tmp; + struct mlx5_ctrl_flow_entry *entry; + struct mlx5_ctrl_flow_entry *tmp; int ret; /* @@ -16274,7 +16274,7 @@ mlx5_flow_hw_ctrl_flow_dmac_vlan_destroy(struct rte_eth_dev *dev, while (entry != NULL) { tmp = LIST_NEXT(entry, next); - if (entry->info.type != MLX5_HW_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC_VLAN || + if (entry->info.type != MLX5_CTRL_FLOW_TYPE_DEFAULT_RX_RSS_UNICAST_DMAC_VLAN || !rte_is_same_ether_addr(addr, &entry->info.uc.dmac) || vlan != entry->info.uc.vlan) { entry = tmp; -- 2.39.5