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 2A39545B04; Thu, 10 Oct 2024 16:17:40 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 14E4E40E28; Thu, 10 Oct 2024 16:15:08 +0200 (CEST) Received: from egress-ip11b.ess.de.barracuda.com (egress-ip11b.ess.de.barracuda.com [18.185.115.215]) by mails.dpdk.org (Postfix) with ESMTP id 5C0C040B9F for ; Thu, 10 Oct 2024 16:14:52 +0200 (CEST) Received: from EUR05-DB8-obe.outbound.protection.outlook.com (mail-db8eur05lp2106.outbound.protection.outlook.com [104.47.17.106]) by mx-outbound20-48.eu-central-1b.ess.aws.cudaops.com (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Thu, 10 Oct 2024 14:14:51 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=mRlxoqnUqd6CHkOEEQVCD39BQ14z3dXVbQ/6jjK1C+IaXM1sur4SOfvSs/qtTkPDJmT3uwzflNJb9CJf/W5Dyei9ohtZQisqYlRaUpAmDXPxtgngYL68FztGnBSWTza37Kyx++gyxYWMfW3+4G36M+russYXwCdEcIiNPoFsIVxW+guUoq/qc6a8vzddgq9ozdWYrZRm5F8H3qQz9CJ/LMVYD3r562yyE8aynu+/Qmr0w/cp+5rmoZsMbTTsAlBKv5ZBbchjqEYkJ4wnNQAg6QF6FGqUpAs7XL6Y/zD08VCTWWnxcMKoV9OUZqLS6mnsFis0oSGxiyR6jSM06EquXg== 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=ls/czwR+LXSJru6PRP9DJ7anHVCg5V5Il4lvpAc938U=; b=EDwSJ0+3QELWbcRNUxRcNwewxp0FDN3GShWE3bxlWebL6K9mjX7WW8cZp5pAPYuyjLTmt2Cj/k+V5CotV17oXpDF1R1kVx3rG6X8F9FCkBEosM0HcYAX+Iba8hCf9dLgWq3xWeIzmU0BxfEG3CsyEhCdqBjE+yecGQdPl+7b22djgCU2obQaau3K7VSZp4EJbbra9ENdNfC5h6qsiECRuHr8EQC5efS2TYhNY495ROftI2tizNfRo4TJjYNJpRoHkCBKXCb4DqEU57yElF/CJozYup09Jj+aKz9Zs8ZyZBck91xFqGXsWQqjpY28R/r8VJ70eH4Ml2nk/Fd2udDEjQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=fail (sender ip is 178.72.21.4) smtp.rcpttodomain=dpdk.org smtp.mailfrom=napatech.com; dmarc=fail (p=reject sp=reject pct=100) action=oreject header.from=napatech.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=napatech.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ls/czwR+LXSJru6PRP9DJ7anHVCg5V5Il4lvpAc938U=; b=Hi3Eq4LDmdvZ8AP8jXxINguWl0lh2J17sPMPb6h7wHly4YIG5ZwT+HkEwl+y9urZYq+DBfS5SP2vhLUZrX6f/T+nxQrjTUcGqsyUGcRZwoHDP9gaiTv695VAX8EbKymgyLhtVryBKeFA0xCPqPGAFr0ptCaYcfibH7pytn96s38= Received: from DU2PR04CA0089.eurprd04.prod.outlook.com (2603:10a6:10:232::34) by DB9P190MB1178.EURP190.PROD.OUTLOOK.COM (2603:10a6:10:220::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8026.23; Thu, 10 Oct 2024 14:14:46 +0000 Received: from DU6PEPF0000B61B.eurprd02.prod.outlook.com (2603:10a6:10:232:cafe::6a) by DU2PR04CA0089.outlook.office365.com (2603:10a6:10:232::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8048.17 via Frontend Transport; Thu, 10 Oct 2024 14:14:46 +0000 X-MS-Exchange-Authentication-Results: spf=fail (sender IP is 178.72.21.4) smtp.mailfrom=napatech.com; dkim=none (message not signed) header.d=none;dmarc=fail action=oreject header.from=napatech.com; Received-SPF: Fail (protection.outlook.com: domain of napatech.com does not designate 178.72.21.4 as permitted sender) receiver=protection.outlook.com; client-ip=178.72.21.4; helo=localhost.localdomain; Received: from localhost.localdomain (178.72.21.4) by DU6PEPF0000B61B.mail.protection.outlook.com (10.167.8.132) with Microsoft SMTP Server id 15.20.8048.13 via Frontend Transport; Thu, 10 Oct 2024 14:14:46 +0000 From: Serhii Iliushyk To: dev@dpdk.org Cc: mko-plv@napatech.com, sil-plv@napatech.com, ckm@napatech.com, andrew.rybchenko@oktetlabs.ru, ferruh.yigit@amd.com, Oleksandr Kolomeiets Subject: [PATCH v3 23/50] net/ntnic: add insert (Tx INS) flow module Date: Thu, 10 Oct 2024 16:13:38 +0200 Message-ID: <20241010141416.4063591-24-sil-plv@napatech.com> X-Mailer: git-send-email 2.45.0 In-Reply-To: <20241010141416.4063591-1-sil-plv@napatech.com> References: <20241006203728.330792-2-sil-plv@napatech.com> <20241010141416.4063591-1-sil-plv@napatech.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DU6PEPF0000B61B:EE_|DB9P190MB1178:EE_ Content-Type: text/plain X-MS-Office365-Filtering-Correlation-Id: 6ab79dfe-8adc-41f1-4042-08dce935e508 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|82310400026|36860700013|1800799024|376014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?Xp9PM+U6lxYknVMD6xVLtkYzRdLs0pt2yzIHrXR24N5A2CV+zJO78bOztn95?= =?us-ascii?Q?q1k+HnuKbiDSMLXTn/mkY/gnlW8Pw7WpLhZQVjN5HdhOhF0/JctNjIppHCMD?= =?us-ascii?Q?hvlnvLYtHgbndhzkoA9PA72zSCgnC9to0XaGByGuRjw+UWapDTo55bEMw/EL?= =?us-ascii?Q?gJ1krcWcuXopwFMxQPXB+xy2rKS+hGJ3UuCrkWB1glk3YsLpYCrg9CVm7dqz?= =?us-ascii?Q?bjbTX/aGB3PVBtoJTVZ34PlbR5TId0089Y2ofRCotXCrVpJ7vBbshgC4uWBd?= =?us-ascii?Q?RoQBMNxxSxy91P0g5ocFe+jevEvwhedcwW55/hSqMt3ULzNh7KsiJajzbGUx?= =?us-ascii?Q?xhPqj5tstaLa2hxlGrATo4BCwKuTB8o8gjicWe2JCw8wIOyo7qaEYC1gkt7q?= =?us-ascii?Q?eLyHKOg2HDbQ7QFmMJ8dGZ6r2MGdrVMzB8bpFr+5tyM++QWnmgYk3uzpTND9?= =?us-ascii?Q?zobEH2V0q8fxEaRER6Bcesk4KG2chcR1VRlrWUdXqefFl3WbwHc6Grevr61c?= =?us-ascii?Q?Ysk2S5fuZhha2mq+oSOL9GGB/lmuJyi8beKljp2+F2nw64sUbymDCdz+bMar?= =?us-ascii?Q?6SL5T1KxyMsmVI9HWGbKGIeYgsw5YqXEqEbH3IVlDGawqhfF+77329xLXwIT?= =?us-ascii?Q?qFWuQyLnhowhCPdcgP5A5DexF5Oc0Te4s0jn25aSrXeBafxxDpk4JEQWYmr5?= =?us-ascii?Q?pH+27AYmvJj9hBM1Zog7ffeJbUaCRgZt+0vlakgWE4QSIzCIuyPGLiC1Fc7h?= =?us-ascii?Q?bZsTe8ZsbS6svav8tdyOH9W0xontC/Y72+ZCNuLrJMjaalYDZcWjo4oonEVv?= =?us-ascii?Q?5Z68Y80l7XMUE01gfX/ZZvn1LWTcnFKU0zlJF8s1o1A6XIRNLwbGP4i+r99m?= =?us-ascii?Q?9yLXfDLoLe/Jz+4BUhC3Yrx17MHfT7tkvvEc/e76sqBJL2LJD08mwMmf4YJh?= =?us-ascii?Q?mbzB2/wrcGuGxy7tf9pEaEE2ZxTJO7lCg0KHxIVwnZzc4UU6XwTRUbytob5V?= =?us-ascii?Q?dLjrX08AYnaPUyfEZQ2uK6+pECkbpX+BJvk4xQRHP61kiAdHF1jtFC+oRMCZ?= =?us-ascii?Q?TeWRFjRkfeHH/3KJnAuu1lmIAvjS3AkpQUKODOJTzYvcfT0J9r6S+CWDOHhR?= =?us-ascii?Q?UZFy2XkWVDsT/OaBaWy6TY2KExTJwa1z1mvEYa5kvQbAh8Ujn4oT2PyzCAct?= =?us-ascii?Q?DKHTMltUz6TrtBoTieZTdlYiTxEQYPLfVMAH19z2ajDHa28Fo0gSf5PuV4W5?= =?us-ascii?Q?QtAuxDKXFfJsDLY1eUC0w8Nfo4d4t2OlBY/7bBWXHtzTnn7rKrv124pEsRPr?= =?us-ascii?Q?en2zouHgT6bDZ1QvoGlXj7O/BKpDuB1CCdtJaY6nMCQRQ0v/+wZy1MKwXgnO?= =?us-ascii?Q?g9W1F3PBEY5K3urXFB7acIxioXfb?= X-Forefront-Antispam-Report: CIP:178.72.21.4; CTRY:DK; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:localhost.localdomain; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(82310400026)(36860700013)(1800799024)(376014); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-ExternalHop-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-ExternalHop-MessageData-0: 895OlBpMmEKJm3RolZWyRFPw2k12/8cdWMJHYJhxm+Q/lNSu84WEW+cM1+JWBH3JkC1C1ppRw/7iU6Ch+Pbuu2khYsZ6pl24wmM3RvKwYgJs7UX6IiK99pOlOFpB+tPQrAlueY+LtcV0xmyFI2bNXkXmQsqlHZ3RLvLfiwR4n2jEinrngdjjOkaL2/lFHtBuZZau0hLmx6tqHc4PjSLs98mJ5eMnRUpfUvgOurT8sUQBx4yfu4ZTm8VOiagU/D1rORPBCe56mYXwI17ASQ65UvavrYdkmPJrNWpUeI88XiGqzVJuIFfvYo9T0CPePS1s5kjFJMf/blmXzkM9obTnSCFxFwmY6MqiInWPeAIs6ovo3mU/FYB2vwnYq6NjkQ8+EMiO6/jFncZNyY6jKxdrnJ8LLM3w3frP9fGMklo0qnamMmoP5JOY6UEVvbnjPNkaiz1EW98ugyhNi4OCFqEqtN7IbjImwR2P2Kg8C/b+SpJMyKaOh5eOtc8W8QNrTFnVwOdbIg8oe7m5Tc9S2WwnKyxgWzfFZHbBJbBl3TJ/jHspGSy8cYKVBRjNAXDeJzungXyItXUSUvFACPjdjhn8fJUmQzfFIwc4SOJVgH4gE8YRHtsOmPbwHF9vG0MaIsDs978hI2mfMvF8+qD9cQ6GTfJzkW1JvQztdxuBfWDGK/Y= X-OriginatorOrg: napatech.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Oct 2024 14:14:46.1391 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 6ab79dfe-8adc-41f1-4042-08dce935e508 X-MS-Exchange-CrossTenant-Id: c4540d0b-728a-4233-9da5-9ea30c7ec3ed X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=c4540d0b-728a-4233-9da5-9ea30c7ec3ed; Ip=[178.72.21.4]; Helo=[localhost.localdomain] X-MS-Exchange-CrossTenant-AuthSource: DU6PEPF0000B61B.eurprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB9P190MB1178 X-BESS-ID: 1728569688-305168-12640-25879-2 X-BESS-VER: 2019.1_20241004.2057 X-BESS-Apparent-Source-IP: 104.47.17.106 X-BESS-Parts: H4sIAAAAAAACA4uuVkqtKFGyUioBkjpK+cVKVpYmhqZAVgZQ0NTcIC3JMMXY1C jF0twiNdU82dzM1NDQNCUJSFoYmCnVxgIAyzcjgEEAAAA= X-BESS-Outbound-Spam-Score: 0.50 X-BESS-Outbound-Spam-Report: Code version 3.2, rules version 3.2.2.259630 [from cloudscan16-205.eu-central-1b.ess.aws.cudaops.com] Rule breakdown below pts rule name description ---- ---------------------- -------------------------------- 0.50 BSF_RULE7568M META: Custom Rule 7568M 0.00 BSF_BESS_OUTBOUND META: BESS Outbound X-BESS-Outbound-Spam-Status: SCORE=0.50 using account:ESS113687 scores of KILL_LEVEL=7.0 tests=BSF_RULE7568M, BSF_BESS_OUTBOUND X-BESS-BRTS-Status: 1 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: Oleksandr Kolomeiets he TX Inserter module injects zeros into an offset of a packet, effectively expanding the packet. Signed-off-by: Oleksandr Kolomeiets --- v3 * Remove newline characters from logs. --- drivers/net/ntnic/meson.build | 1 + .../nthw/flow_api/flow_backend/flow_backend.c | 13 ++++ .../ntnic/nthw/flow_filter/flow_nthw_tx_ins.c | 62 +++++++++++++++++++ .../ntnic/nthw/flow_filter/flow_nthw_tx_ins.h | 35 +++++++++++ .../ntnic/nthw/supported/nthw_fpga_mod_defs.h | 1 + .../ntnic/nthw/supported/nthw_fpga_reg_defs.h | 2 + .../nthw/supported/nthw_fpga_reg_defs_ins.h | 30 +++++++++ .../supported/nthw_fpga_reg_defs_tx_ins.h | 23 +++++++ 8 files changed, 167 insertions(+) create mode 100644 drivers/net/ntnic/nthw/flow_filter/flow_nthw_tx_ins.c create mode 100644 drivers/net/ntnic/nthw/flow_filter/flow_nthw_tx_ins.h create mode 100644 drivers/net/ntnic/nthw/supported/nthw_fpga_reg_defs_ins.h create mode 100644 drivers/net/ntnic/nthw/supported/nthw_fpga_reg_defs_tx_ins.h diff --git a/drivers/net/ntnic/meson.build b/drivers/net/ntnic/meson.build index cc5e6fe100..7e0900f0eb 100644 --- a/drivers/net/ntnic/meson.build +++ b/drivers/net/ntnic/meson.build @@ -59,6 +59,7 @@ sources = files( 'nthw/flow_filter/flow_nthw_rpp_lr.c', 'nthw/flow_filter/flow_nthw_slc_lr.c', 'nthw/flow_filter/flow_nthw_tx_cpy.c', + 'nthw/flow_filter/flow_nthw_tx_ins.c', 'nthw/model/nthw_fpga_model.c', 'nthw/nthw_platform.c', 'nthw/nthw_rac.c', diff --git a/drivers/net/ntnic/nthw/flow_api/flow_backend/flow_backend.c b/drivers/net/ntnic/nthw/flow_api/flow_backend/flow_backend.c index 8b83425545..ad62c4c156 100644 --- a/drivers/net/ntnic/nthw/flow_api/flow_backend/flow_backend.c +++ b/drivers/net/ntnic/nthw/flow_api/flow_backend/flow_backend.c @@ -18,6 +18,7 @@ #include "flow_nthw_pdb.h" #include "flow_nthw_rpp_lr.h" #include "flow_nthw_tx_cpy.h" +#include "flow_nthw_tx_ins.h" #include "ntnic_mod_reg.h" #include "nthw_fpga_model.h" #include "hw_mod_backend.h" @@ -43,6 +44,7 @@ static struct backend_dev_s { struct hfu_nthw *p_hfu_nthw; /* TPE module */ struct rpp_lr_nthw *p_rpp_lr_nthw; /* TPE module */ struct tx_cpy_nthw *p_tx_cpy_nthw; /* TPE module */ + struct tx_ins_nthw *p_tx_ins_nthw; /* TPE module */ struct csu_nthw *p_csu_nthw; /* TPE module */ struct ifr_nthw *p_ifr_nthw; /* TPE module */ } be_devs[MAX_PHYS_ADAPTERS]; @@ -1831,6 +1833,16 @@ const struct flow_api_backend_ops *bin_flow_backend_init(nthw_fpga_t *p_fpga, vo be_devs[physical_adapter_no].p_csu_nthw = NULL; } + /* Init nthw TX_INS */ + if (tx_ins_nthw_init(NULL, p_fpga, physical_adapter_no) == 0) { + struct tx_ins_nthw *ptr = tx_ins_nthw_new(); + tx_ins_nthw_init(ptr, p_fpga, physical_adapter_no); + be_devs[physical_adapter_no].p_tx_ins_nthw = ptr; + + } else { + be_devs[physical_adapter_no].p_tx_ins_nthw = NULL; + } + be_devs[physical_adapter_no].adapter_no = physical_adapter_no; *dev = (void *)&be_devs[physical_adapter_no]; @@ -1852,6 +1864,7 @@ static void bin_flow_backend_done(void *dev) hfu_nthw_delete(be_dev->p_hfu_nthw); rpp_lr_nthw_delete(be_dev->p_rpp_lr_nthw); tx_cpy_nthw_delete(be_dev->p_tx_cpy_nthw); + tx_ins_nthw_delete(be_dev->p_tx_ins_nthw); } static const struct flow_backend_ops ops = { diff --git a/drivers/net/ntnic/nthw/flow_filter/flow_nthw_tx_ins.c b/drivers/net/ntnic/nthw/flow_filter/flow_nthw_tx_ins.c new file mode 100644 index 0000000000..355b54ddb1 --- /dev/null +++ b/drivers/net/ntnic/nthw/flow_filter/flow_nthw_tx_ins.c @@ -0,0 +1,62 @@ +/* + * SPDX-License-Identifier: BSD-3-Clause + * Copyright(c) 2023 Napatech A/S + */ + +#include +#include + +#include "ntlog.h" +#include "nthw_drv.h" +#include "nthw_register.h" + +#include "flow_nthw_tx_ins.h" + +struct tx_ins_nthw *tx_ins_nthw_new(void) +{ + struct tx_ins_nthw *p = malloc(sizeof(struct tx_ins_nthw)); + + if (p) + (void)memset(p, 0, sizeof(*p)); + + return p; +} + +void tx_ins_nthw_delete(struct tx_ins_nthw *p) +{ + if (p) { + (void)memset(p, 0, sizeof(*p)); + free(p); + } +} + +int tx_ins_nthw_init(struct tx_ins_nthw *p, nthw_fpga_t *p_fpga, int n_instance) +{ + const char *const p_adapter_id_str = p_fpga->p_fpga_info->mp_adapter_id_str; + nthw_module_t *p_mod = nthw_fpga_query_module(p_fpga, MOD_TX_INS, n_instance); + + assert(n_instance >= 0 && n_instance < 256); + + if (p == NULL) + return p_mod == NULL ? -1 : 0; + + if (p_mod == NULL) { + NT_LOG(ERR, NTHW, "%s: TxIns %d: no such instance", p_adapter_id_str, + n_instance); + return -1; + } + + p->mp_fpga = p_fpga; + p->m_physical_adapter_no = (uint8_t)n_instance; + p->m_tx_ins = nthw_fpga_query_module(p_fpga, MOD_TX_INS, n_instance); + + p->mp_rcp_ctrl = nthw_module_get_register(p->m_tx_ins, INS_RCP_CTRL); + p->mp_rcp_addr = nthw_register_get_field(p->mp_rcp_ctrl, INS_RCP_CTRL_ADR); + p->mp_rcp_cnt = nthw_register_get_field(p->mp_rcp_ctrl, INS_RCP_CTRL_CNT); + p->mp_rcp_data = nthw_module_get_register(p->m_tx_ins, INS_RCP_DATA); + p->mp_rcp_data_dyn = nthw_register_get_field(p->mp_rcp_data, INS_RCP_DATA_DYN); + p->mp_rcp_data_ofs = nthw_register_get_field(p->mp_rcp_data, INS_RCP_DATA_OFS); + p->mp_rcp_data_len = nthw_register_get_field(p->mp_rcp_data, INS_RCP_DATA_LEN); + + return 0; +} diff --git a/drivers/net/ntnic/nthw/flow_filter/flow_nthw_tx_ins.h b/drivers/net/ntnic/nthw/flow_filter/flow_nthw_tx_ins.h new file mode 100644 index 0000000000..4e7c4133da --- /dev/null +++ b/drivers/net/ntnic/nthw/flow_filter/flow_nthw_tx_ins.h @@ -0,0 +1,35 @@ +/* + * SPDX-License-Identifier: BSD-3-Clause + * Copyright(c) 2023 Napatech A/S + */ + +#ifndef __FLOW_NTHW_TX_INS_H__ +#define __FLOW_NTHW_TX_INS_H__ + +#include + +#include "nthw_fpga_model.h" + +struct tx_ins_nthw { + uint8_t m_physical_adapter_no; + nthw_fpga_t *mp_fpga; + + nthw_module_t *m_tx_ins; + + nthw_register_t *mp_rcp_ctrl; + nthw_field_t *mp_rcp_addr; + nthw_field_t *mp_rcp_cnt; + + nthw_register_t *mp_rcp_data; + nthw_field_t *mp_rcp_data_dyn; + nthw_field_t *mp_rcp_data_ofs; + nthw_field_t *mp_rcp_data_len; +}; + +struct tx_ins_nthw *tx_ins_nthw_new(void); +void tx_ins_nthw_delete(struct tx_ins_nthw *p); +int tx_ins_nthw_init(struct tx_ins_nthw *p, nthw_fpga_t *p_fpga, int n_instance); + +int tx_ins_nthw_setup(struct tx_ins_nthw *p, int n_idx, int n_idx_cnt); + +#endif /* __FLOW_NTHW_TX_INS_H__ */ diff --git a/drivers/net/ntnic/nthw/supported/nthw_fpga_mod_defs.h b/drivers/net/ntnic/nthw/supported/nthw_fpga_mod_defs.h index 14e031dc69..0d5385a313 100644 --- a/drivers/net/ntnic/nthw/supported/nthw_fpga_mod_defs.h +++ b/drivers/net/ntnic/nthw/supported/nthw_fpga_mod_defs.h @@ -39,6 +39,7 @@ #define MOD_SDC (0xd2369530UL) #define MOD_SLC_LR (0x969fc50bUL) #define MOD_TX_CPY (0x60acf217UL) +#define MOD_TX_INS (0x59afa100UL) #define MOD_IDX_COUNT (14) /* aliases - only aliases go below this point */ diff --git a/drivers/net/ntnic/nthw/supported/nthw_fpga_reg_defs.h b/drivers/net/ntnic/nthw/supported/nthw_fpga_reg_defs.h index 6eebab65a2..605196e30e 100644 --- a/drivers/net/ntnic/nthw/supported/nthw_fpga_reg_defs.h +++ b/drivers/net/ntnic/nthw/supported/nthw_fpga_reg_defs.h @@ -26,6 +26,7 @@ #include "nthw_fpga_reg_defs_i2cm.h" #include "nthw_fpga_reg_defs_ifr.h" #include "nthw_fpga_reg_defs_iic.h" +#include "nthw_fpga_reg_defs_ins.h" #include "nthw_fpga_reg_defs_km.h" #include "nthw_fpga_reg_defs_mac_pcs.h" #include "nthw_fpga_reg_defs_pcie3.h" @@ -40,6 +41,7 @@ #include "nthw_fpga_reg_defs_slc.h" #include "nthw_fpga_reg_defs_slc_lr.h" #include "nthw_fpga_reg_defs_tx_cpy.h" +#include "nthw_fpga_reg_defs_tx_ins.h" /* aliases */ diff --git a/drivers/net/ntnic/nthw/supported/nthw_fpga_reg_defs_ins.h b/drivers/net/ntnic/nthw/supported/nthw_fpga_reg_defs_ins.h new file mode 100644 index 0000000000..8aaef2a8f6 --- /dev/null +++ b/drivers/net/ntnic/nthw/supported/nthw_fpga_reg_defs_ins.h @@ -0,0 +1,30 @@ +/* + * SPDX-License-Identifier: BSD-3-Clause + * Copyright(c) 2024 Napatech A/S + */ + +/* + * nthw_fpga_reg_defs_ins.h + * + * Auto-generated file - do *NOT* edit + * + */ + +#ifndef _NTHW_FPGA_REG_DEFS_INS_ +#define _NTHW_FPGA_REG_DEFS_INS_ + +/* INS */ +#define NTHW_MOD_INS (0x24df4b78UL) +#define INS_RCP_CTRL (0x93de4e05UL) +#define INS_RCP_CTRL_ADR (0x3ae620a8UL) +#define INS_RCP_CTRL_CNT (0x2aeeb979UL) +#define INS_RCP_DATA (0x3c0fcc1cUL) +#define INS_RCP_DATA_DYN (0xc6aa4fccUL) +#define INS_RCP_DATA_LEN (0x2ece4329UL) +#define INS_RCP_DATA_OFS (0x64a3c26aUL) + +#endif /* _NTHW_FPGA_REG_DEFS_INS_ */ + +/* + * Auto-generated file - do *NOT* edit + */ diff --git a/drivers/net/ntnic/nthw/supported/nthw_fpga_reg_defs_tx_ins.h b/drivers/net/ntnic/nthw/supported/nthw_fpga_reg_defs_tx_ins.h new file mode 100644 index 0000000000..26635bd0a2 --- /dev/null +++ b/drivers/net/ntnic/nthw/supported/nthw_fpga_reg_defs_tx_ins.h @@ -0,0 +1,23 @@ +/* + * SPDX-License-Identifier: BSD-3-Clause + * Copyright(c) 2024 Napatech A/S + */ + +/* + * nthw_fpga_reg_defs_tx_ins.h + * + * Auto-generated file - do *NOT* edit + * + */ + +#ifndef _NTHW_FPGA_REG_DEFS_TX_INS_ +#define _NTHW_FPGA_REG_DEFS_TX_INS_ + +/* TX_INS */ +#define NTHW_MOD_TX_INS (0x59afa100UL) + +#endif /* _NTHW_FPGA_REG_DEFS_TX_INS_ */ + +/* + * Auto-generated file - do *NOT* edit + */ -- 2.45.0