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 58880460D6; Tue, 21 Jan 2025 18:08:26 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A1CD4402C9; Tue, 21 Jan 2025 18:08:25 +0100 (CET) Received: from egress-ip42a.ess.de.barracuda.com (egress-ip42a.ess.de.barracuda.com [18.185.115.201]) by mails.dpdk.org (Postfix) with ESMTP id 301974027D for ; Tue, 21 Jan 2025 18:08:24 +0100 (CET) Received: from EUR02-AM0-obe.outbound.protection.outlook.com (mail-am0eur02lp2238.outbound.protection.outlook.com [104.47.11.238]) by mx-outbound11-0.eu-central-1a.ess.aws.cudaops.com (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Tue, 21 Jan 2025 17:08:23 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=H2LmchOLF6M9LPukzyu9080yMF1qWQX4BWKqNaUSG2hzodEZn7UbZfOcU6/GcCqzg5NF4JYhB8627Usf39CxC8/wlQduBdyv0kwoFF9a1Q4jMGLrGtDhYKK8Jwig6ZeGb157iYgpoz9BfBQZzaiWncI/XKsuhkFDSpsK+dgZRVDwyLEvr0fGp6/uRUaHYZM759riCPo8tvtI1lVSbGFyfK0IQ7uNmXCQRmvMWKCsd5r9znJtsE0X5IHi8uOMalsOR61brdSb1pMcVqzGYnWAsQqqyqjMAbzNtG0C4Kx+PzzvmY1VCyrs341nbfEAYAoH9ze8g5sa/WjqmN+T7yDsig== 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=JVIH8/dvec91XX2uLMfuS18hD2JwWvPWwLrQiTzfGwQ=; b=HRlynZQLUUtjCwF1BOiaI+pLhkioV1YPFI3r4/GaOjlwEtox20uwL0tm+Aajqs4tb+/OJe6zinHKrX5ysTqgtuoRkIJAVI22yf4v7ZsLI4YIC9SIJvonQWZTtCyXHM2KW5fRtD7LZ3WWUYGUPjtSRwPEhkH9r7ZOs0fxCmhCXywxyRbiSIZGje6Be98Yp3yrOzCcboenXCo5LPU+zwOJqKgIDddsWtyhTUUGzl5Tobo6xiTVnc5G7FANmbVNgObt35TyO47iUwCPjZFzfo4SJX+/ZNUIrShJ3Z+6BW2rBpt7WiyGw4duR03GoUh5+eAy5Hpm8+1kTvddZGDcV843OA== 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=JVIH8/dvec91XX2uLMfuS18hD2JwWvPWwLrQiTzfGwQ=; b=hL9cJMXWD3CuGjAlpVb1VwAXulSBTOsg6bDzh/7jB/No0huQPyBKHAuLe9LfVMihEdcNeizXUWc/CsSyISRC4YsMIPyl4gxNrOajotFg/1d+7CdL+KhL2wHIw8e7BuAlzOm9rJ9cbtNdbS8UHes95wNQCZQGoQby9moLYRetggM= Received: from AS4P251CA0026.EURP251.PROD.OUTLOOK.COM (2603:10a6:20b:5d3::15) by DBAP190MB0840.EURP190.PROD.OUTLOOK.COM (2603:10a6:10:1a2::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8356.17; Tue, 21 Jan 2025 17:08:22 +0000 Received: from AM2PEPF0001C70A.eurprd05.prod.outlook.com (2603:10a6:20b:5d3:cafe::e8) by AS4P251CA0026.outlook.office365.com (2603:10a6:20b:5d3::15) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.8356.21 via Frontend Transport; Tue, 21 Jan 2025 17:08:22 +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 AM2PEPF0001C70A.mail.protection.outlook.com (10.167.16.198) with Microsoft SMTP Server id 15.20.8377.8 via Frontend Transport; Tue, 21 Jan 2025 17:08:22 +0000 From: Serhii Iliushyk To: dev@dpdk.org Cc: mko-plv@napatech.com, sil-plv@napatech.com, ckm@napatech.com, stephen@networkplumber.org, Danylo Vodopianov Subject: [PATCH v1 01/31] net/ntnic: fix index verification Date: Tue, 21 Jan 2025 18:07:39 +0100 Message-ID: <20250121170814.3252171-2-sil-plv@napatech.com> X-Mailer: git-send-email 2.45.0 In-Reply-To: <20250121170814.3252171-1-sil-plv@napatech.com> References: <20250121170814.3252171-1-sil-plv@napatech.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AM2PEPF0001C70A:EE_|DBAP190MB0840:EE_ Content-Type: text/plain X-MS-Office365-Filtering-Correlation-Id: ba741a96-398f-4482-9f16-08dd3a3e3609 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|36860700013|1800799024|376014|82310400026; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?8ZH4FWwbKseD07elQ4YtlG/08MhVkk+oo3juLOmY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ii?Q?6OTF0irbUqzf7Rke3dcABeHdcBXZyep1OKqGH0/BkiFpnsInM/2D6jRAEWBq?= =?us-ascii?Q?Jc0UNJQ5jO2QVMOX1dwiOO7NqxkDmKMWyAWSyOiOQfks1cgDwzmstPS1l/r6?= =?us-ascii?Q?+Wf39RxHKQhsakhhIjiiXq0+ZtvP7+2gWJ5SbesDyZwZvGpUdfOR9r6qpE5A?= =?us-ascii?Q?wdg9ye5ZQApIOrcKQqnTWSHMfsTVdYFVbM+xmlj+i7fUjPlenK/+5djEoo/p?= =?us-ascii?Q?RwnwwzJJCU7Nns/eFmWwuduNjXAVadnuk2p2oYCHGWLIwhrELO8rAXF3UzPC?= =?us-ascii?Q?WtWYDd13YE1UTxiVof743ODUvxVGbJlkfOjT2n81fF6EY2MQ/PNQQOAAicxG?= =?us-ascii?Q?cycWyoQvhFTc/MZUg+uE/NcEBtqfaRjPHT5/2dZafr0nOfZpcBwRUu98LKWV?= =?us-ascii?Q?k+wFA3hVUWgRmwQJdoKa9A28pmu5Aas7BuwffyIaoDrzH+48UrvzBcE/kVp+?= =?us-ascii?Q?PkjwK2mbUKl6y11WTO1Mxh8AnkPgkSNUu1JiVsFpvWklqOrybExUoHLG6L27?= =?us-ascii?Q?K5uhYnlsegR4r3VjxgUtKQxN9eFd3XTCIcXKfgIEWi9a8PsqrGQ6GFkkPiog?= =?us-ascii?Q?yjRUk7Ahoms574c=3D?= 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)(1800799024)(376014)(82310400026); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-ExternalHop-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-ExternalHop-MessageData-0: tUaDHpt920Ta4LlIIH+Hf5/pYM5GOPXybR2GpRExWl9HyUmpNCAHDiReCTF2whFAevA5tlkw27oRXHy9tFHg7zU7sViw2oNkCuSYwe+q05BxWgOhvVMX2YSnRTKM4P1RcajuR7d5CAgEnL2BdbracZD95ht4VK6HVloabBNYPo6bxWNgpoNVBVjnb3dLJKLQ+GADeP9MiODL0IQBcLRWB2NQjh8k+3NIcXK3YJo+SecWFgCbxUZtWp4y9ynsrkZprPbh7p8u20AkdakjkXMzQulbSHJ4cTsqG1CeRQsMpwGaBfs2Od6E8aokdMN/H3RjK12KEsDB7jdA9GfRXF/LEmWn2n8NO+fW71r3qbRlDVgnp75gwv+JSPXN4DJZGFJ0G+xh9llk+VD1Ir8TJJWUDfJnYKQZBO6M8DJS7b+vrKmgsqydWXzOcVmfSDRoJP0Pdkbx33bu4cwZjO5si3F7b1u3Yip9iqLGbQ05snI3F44i40ScnWAUpUYFg916evWd4N7ISooBFkympBYCYhDQqi33iajZlwvOFk/E2HZAhp1H95ZpRo+QxMw3XLPpoPLtUcNzVz96HykIyMjAIciaqAlk6/XBnTcbms4gzdc693ITYSgQE2mcDUdHToSNs26/4z29E6U4SqS0D+dZqQAf6g== X-OriginatorOrg: napatech.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Jan 2025 17:08:22.3743 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: ba741a96-398f-4482-9f16-08dd3a3e3609 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: AM2PEPF0001C70A.eurprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DBAP190MB0840 X-BESS-ID: 1737479303-302816-13351-7955-1 X-BESS-VER: 2019.1_20250117.1903 X-BESS-Apparent-Source-IP: 104.47.11.238 X-BESS-Parts: H4sIAAAAAAACA4uuVkqtKFGyUioBkjpK+cVKVoYG5gZAVgZQ0Mgg2TLF0CIxyS I5LS0pOS3RMi3J0NDcNNk0zdLI0jhVqTYWAJJNXIlBAAAA X-BESS-Outbound-Spam-Score: 0.00 X-BESS-Outbound-Spam-Report: Code version 3.2, rules version 3.2.2.261957 [from cloudscan21-179.eu-central-1b.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 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org From: Danylo Vodopianov CI found couple coverity problems which were fixed in this commit. CID: 448974, 448977, 448978 (OVERRUN). These issues were fixed with updating index verification statement. Coverity issue: 448974 Fixes: effa04693274 ("net/ntnic: add statistics") Signed-off-by: Danylo Vodopianov --- drivers/net/ntnic/ntnic_filter/ntnic_filter.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ntnic/ntnic_filter/ntnic_filter.c b/drivers/net/ntnic/ntnic_filter/ntnic_filter.c index 4c8503f689..e00b10ff82 100644 --- a/drivers/net/ntnic/ntnic_filter/ntnic_filter.c +++ b/drivers/net/ntnic/ntnic_filter/ntnic_filter.c @@ -1201,7 +1201,7 @@ static int poll_statistics(struct pmd_internals *internals) const int if_index = internals->n_intf_no; uint64_t last_stat_rtc = 0; - if (!p_nt4ga_stat || if_index < 0 || if_index > NUM_ADAPTER_PORTS_MAX) + if (!p_nt4ga_stat || if_index < 0 || if_index >= NUM_ADAPTER_PORTS_MAX) return -1; assert(rte_tsc_freq > 0); -- 2.45.0