Message ID | 20241030213940.3470062-14-sil-plv@napatech.com (mailing list archive) |
---|---|
State | Accepted, archived |
Delegated to: | Ferruh Yigit |
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 8EDD145BCC; Wed, 30 Oct 2024 22:41:25 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 788A743478; Wed, 30 Oct 2024 22:40:22 +0100 (CET) Received: from egress-ip11a.ess.de.barracuda.com (egress-ip11a.ess.de.barracuda.com [18.184.203.234]) by mails.dpdk.org (Postfix) with ESMTP id 0B415433D2 for <dev@dpdk.org>; Wed, 30 Oct 2024 22:40:08 +0100 (CET) Received: from EUR05-DB8-obe.outbound.protection.outlook.com (mail-db8eur05lp2106.outbound.protection.outlook.com [104.47.17.106]) by mx-outbound11-85.eu-central-1a.ess.aws.cudaops.com (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Wed, 30 Oct 2024 21:40:05 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=kXz3lWzNVqRAhJnyMJ6IGZf5j1GT+r06zBHs2LmyEKgTTzhGoaJEFcNNgFF3u0IGmSMSremawWvM8sh2/55aXSA+O1LBs45tv40SQBKMAWvUuF8idPQhkmLbic9qsWnyNwtNW4KsXMyqszkg1231zW98+tJrIgXvryiXPuyA6VztAaQUUz+z0SouR9IPLcB/1mdUvnotwNEAVtUnE7KfR5tpQPiNamieFixTe+WWqwrXjXd9QJWwWLne9c8X4AsedIKTFO4aSzTizS20IxOSiLUR0MGGJK3EANsruqW30+eXoY3lnDL0u8fZEwX+V+/xVE2VOOAJ+komwT+6lEU9GQ== 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=U68BvGwErdySiMm9SpZA8piB1vj6cszSQZMUY0HwCx4=; b=eSSTu72cJNBTMZOZISNd5bD3rme4Km2ox2A+7Fv9Yu9hc0vU7+GrezAUF1Sa0gljgZtXdj+B/AfPZrAAY0iYDmpv3ssR3VmRveFMxutTGDRKEaEJcPV7IGYBCHowRS98F/RXdDSBlAWoE+tiEp42NnzlCoPLYo9Zixxc28lk9daxKbembWA0ZGeAN0XGFw9GncSgvOBrVZUSh3z6rRU8GTPsx4ua/t+n/G2xOr6DBUaS7FyBFvnl5nzGBRY00lr78232VI1F+MzFolaOFEvnYJZrKId5BNCksPHGVj+N4sc+smSy6u7ZvBAw0kJOxGDggHRXah/yb7rDH9ynokgqnA== 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=U68BvGwErdySiMm9SpZA8piB1vj6cszSQZMUY0HwCx4=; b=awT9ji05JJWPe0uHy89DuJa2Mea0F3z3OUvoYN1Ss2cjdzz28Q5AAbbZgoDHVKewjkh1CfMJaT/N24AcJsFYU8m+I11R26JcQdDUIlE3rpdzmVCM49pl5yVWwFt3F6sCM+VtbjGesjZdgNRdnTWPs09KPgu67o9be19iRz0HqF0= Received: from DUZPR01CA0015.eurprd01.prod.exchangelabs.com (2603:10a6:10:3c3::18) by DU0P190MB1953.EURP190.PROD.OUTLOOK.COM (2603:10a6:10:3bb::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8093.25; Wed, 30 Oct 2024 21:40:04 +0000 Received: from DU2PEPF00028D13.eurprd03.prod.outlook.com (2603:10a6:10:3c3:cafe::63) by DUZPR01CA0015.outlook.office365.com (2603:10a6:10:3c3::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8114.20 via Frontend Transport; Wed, 30 Oct 2024 21:40:04 +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 DU2PEPF00028D13.mail.protection.outlook.com (10.167.242.27) with Microsoft SMTP Server id 15.20.8114.16 via Frontend Transport; Wed, 30 Oct 2024 21:40:04 +0000 From: Serhii Iliushyk <sil-plv@napatech.com> To: dev@dpdk.org Cc: mko-plv@napatech.com, sil-plv@napatech.com, ckm@napatech.com, andrew.rybchenko@oktetlabs.ru, ferruh.yigit@amd.com, stephen@networkplumber.org Subject: [PATCH v5 13/80] net/ntnic: add action drop Date: Wed, 30 Oct 2024 22:38:20 +0100 Message-ID: <20241030213940.3470062-14-sil-plv@napatech.com> X-Mailer: git-send-email 2.45.0 In-Reply-To: <20241030213940.3470062-1-sil-plv@napatech.com> References: <20241021210527.2075431-1-sil-plv@napatech.com> <20241030213940.3470062-1-sil-plv@napatech.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DU2PEPF00028D13:EE_|DU0P190MB1953:EE_ Content-Type: text/plain X-MS-Office365-Filtering-Correlation-Id: d7d1a823-ab69-4084-7ee3-08dcf92b6a58 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|36860700013|376014|1800799024|82310400026; X-Microsoft-Antispam-Message-Info: OLO4Q1ErlXf+MGoImXtaAFFCbsJcHebeyoMhjGxE0s3KDuFzUKuIEfd2sGo5VdSOQOPuQfaBUAx1Zp485D2VFWWN/g1OTsVz0CzbEwupAeGwKBc2X0uoNCGtNT25+rZ9JXjUG6ZvaIHhDWX9d5Gd5nDHeKsbVIml/62tsHihb91DjvOsBG3hrmJZOR0jj7TV3q3I1n88io0ZXHosDbboT3QyP8WPPPSiRcn++/B7uO16oVAnmK/C/S0G2GWXPrXb2ehQTdhNR/eEMs9Fu8lwv+womZM5s4iXkyb0SECK9tyD+7E5D4xRk2LLHMB46fTLvSKX62NbzE/F/UVxQ/hjKGG0Xp2LIAF641I10jOsrNUEVMcnnwTNevkhbR1knY4HSRsVaAif7Hnp2m21P8noHxAXTWDBScip+Oq3yFHWyCh0n+5KCaC5clVB6w/V2DIg9JgpUUmhDSz5GE7G+GzKXqcR43TliSh/a4ujCgT8CPxSHvzEqMGaUKqVhIDMz4O0fmud4BSDHG07lhu6A6bUOW0IfS95+aOYmlYsnwJaS2J/XDBArKoXV0kBhS/icvvondjPH7X0s9FoGhoHwY3fqeTtrD1kbFh7gpEewtDoFW+oDDK+qQC3iqoSgLuuITzqR/MzTjWO5Vn97LOq4FuKnBJIaHoxO8Ksvum1RtnbW9fUMGEE/xm/eLc/8gvEncX9vKw0gLbIwsZdtXHYlyLqPe/bLceXhT6XXiK+qwHneONrjp1CNtQ83Pe0CpuYeBYQ53R3hNT5uzy3XX/Yhce4hjctH7HBuM/CvLK4N8v37DFQaDDL6wsNoEpaXzQ+re7w25AeR70O338Eb/isduC9L493YJgOQmGCEeK/4elRKdjyxArHK3jqg/X+4hj8ZgvqJHX/I4b5y9xdTo6M5Fls6IWRrPC73ubE4g6YWK/4obZF1fFj4jt3+ABX+Tu3Itaxo4uhK8Xz1PmRLb5+FxZVJE9oI+gz2FAB3wLK4FMJjcCk3g0Naa/JzWKTGpH31/0EC7P8w8erGHL3fx/Yo02V5TGiIx45ewHCMEwoSKmgtM5I0hXUREA36Zbbtx+wsj5NIUOBwVXIysTRbHkA1FSxZwf+2n+nzpxFew0wRhdjBclQTDvBEHHahpJgvvt1OOQYqRX6H5888LDSbKtURxB3dL55hBiwXIZTVQnLcxfA5svNRQWg64zU60uKasMnLQY578d4D2jbjk4rRfJ6mPksJjhV4GZqedWXMu+L26aaLeXsijf1t9XOx+xKiuUJ0pak+sFajZo084nv3rpRL4oWzJysw6YHTl4PE7Dqg7DdX3bnlG6/6ktPl2VWieKfPLCnHT9bo4o8ac7T8VzpyavgGdy3fhpBNKlhSlwOlrcPVnfaWQye2RQrjJliz44o2z3d4cqoeE6K++H+ZPgsZtRHqw== 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)(36860700013)(376014)(1800799024)(82310400026); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-ExternalHop-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-ExternalHop-MessageData-0: CvmN3gKwQ/sTpvhZMQd94KMdCMTJvhki5iT9KMEzC68xD7XyywTVVdxT0Ehz00d9ozjwjhJHI1xp1YdNST5vuiJSAY7+hsHR6J9HESROp1Ghh9qGR8yzQDVQRw2AHv9Sd/RwXMzgjvjC5h1vQXc3KsEHSkDXfi5GLQFp+0VRxWebBsQtGheANiY3v9JDEAlZsxyA1jgC2nAf9VY118NhlOzu5tfwpASadpkoOwQKnVXJKB/hoSFxHItGoIRApLk+zo0OcaH2NKTdhXk/M2yXrmZLaX4LjTS6XF3ybw13X8t4pKw0HpM8Z5oErEJ7Ozi33TM6dtZIWs/eGLFJ3sytLfTfSExHUkwT3yFGhKD+PioEjnF51wycpXE4vIuJCzFfWvl6W/lsL62bLaLRorZqjMTRg+O7MeozCNrsGd3bVC6BMpJOQi4vOw4//iJ5ZdyBRtna2wQi13+k6lwKD1lx2ZdyqrDhQYXMxZxbEp5tPWRcKVThtSnseNbMgu3j4g8cHz7lLXFobdEB5iJLc3K4s6LgGzWIWqtCjkWrSKBZ9b/BED0dw14tE/fl+CBj3eHBGRSbCcPkJQWA7VxsbgtEfDnNYhGASrPrx721jpdPsRwFCNJeD6aBE189I3t3y0gI+w7a/bS/DDxGCtn6I+eZGPaSWQ9iR8oc/sx8mcvDm1I= X-OriginatorOrg: napatech.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Oct 2024 21:40:04.0206 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: d7d1a823-ab69-4084-7ee3-08dcf92b6a58 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: DU2PEPF00028D13.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU0P190MB1953 X-BESS-ID: 1730324405-302901-12792-43449-1 X-BESS-VER: 2019.1_20241018.1852 X-BESS-Apparent-Source-IP: 104.47.17.106 X-BESS-Parts: H4sIAAAAAAACA4uuVkqtKFGyUioBkjpK+cVKVoamFpZAVgZQ0CIt0TDZ1NTQws zSwDAtJckiKc0s0dgsycDIwtDS3DhNqTYWAFZEV6NBAAAA X-BESS-Outbound-Spam-Score: 0.00 X-BESS-Outbound-Spam-Report: Code version 3.2, rules version 3.2.2.260091 [from cloudscan15-25.eu-central-1a.ess.aws.cudaops.com] Rule breakdown below pts rule name description ---- ---------------------- -------------------------------- 0.00 BSF_BESS_OUTBOUND META: BESS Outbound X-BESS-Outbound-Spam-Status: SCORE=0.00 using account:ESS113687 scores of KILL_LEVEL=7.0 tests=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 <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 |
Provide flow filter and statistics support
|
|
Checks
Context | Check | Description |
---|---|---|
ci/checkpatch | success | coding style OK |
Commit Message
Serhii Iliushyk
Oct. 30, 2024, 9:38 p.m. UTC
Add possibility to use RTE_FLOW_ACTION_TYPE_DROP.
Signed-off-by: Serhii Iliushyk <sil-plv@napatech.com>
---
doc/guides/nics/features/ntnic.ini | 1 +
.../profile_inline/flow_api_profile_inline.c | 12 ++++++++++++
2 files changed, 13 insertions(+)
diff --git a/doc/guides/nics/features/ntnic.ini b/doc/guides/nics/features/ntnic.ini index f3334fc86d..372653695d 100644 --- a/doc/guides/nics/features/ntnic.ini +++ b/doc/guides/nics/features/ntnic.ini @@ -17,6 +17,7 @@ x86-64 = Y any = Y [rte_flow actions] +drop = Y jump = Y mark = Y port_id = Y diff --git a/drivers/net/ntnic/nthw/flow_api/profile_inline/flow_api_profile_inline.c b/drivers/net/ntnic/nthw/flow_api/profile_inline/flow_api_profile_inline.c index 9dfa211095..1d949b3b91 100644 --- a/drivers/net/ntnic/nthw/flow_api/profile_inline/flow_api_profile_inline.c +++ b/drivers/net/ntnic/nthw/flow_api/profile_inline/flow_api_profile_inline.c @@ -419,6 +419,18 @@ static int interpret_flow_actions(const struct flow_eth_dev *dev, break; + case RTE_FLOW_ACTION_TYPE_DROP: + NT_LOG(DBG, FILTER, "Dev:%p: RTE_FLOW_ACTION_TYPE_DROP", dev); + + if (action[aidx].conf) { + fd->dst_id[fd->dst_num_avail].owning_port_id = 0; + fd->dst_id[fd->dst_num_avail].id = 0; + fd->dst_id[fd->dst_num_avail].type = PORT_NONE; + fd->dst_num_avail++; + } + + break; + default: NT_LOG(ERR, FILTER, "Invalid or unsupported flow action received - %i", action[aidx].type);