From: Oleksandr Kolomeiets <okl-plv@napatech.com>
To: dev@dpdk.org
Cc: mko-plv@napatech.com, sil-plv@napatech.com, ckm@napatech.com,
stephen@networkplumber.org, thomas@monjalon.net
Subject: [PATCH v1 00/25] net/ntnic: fixes and improvements
Date: Wed, 30 Apr 2025 15:48:12 +0200 [thread overview]
Message-ID: <20250430134840.402553-1-okl-plv@napatech.com> (raw)
* Fix issues detected by static code analyzers CoverityScan and PVS studio
- PVS studio: https://inbox.dpdk.org/dev/CAOaVG170qdNxDFsTjCvJhZafY-Fs8e98xPBa3q8U--WX+K_Qvw@mail.gmail.com/1-a.txt
* Fix requested issues mentioned here https://inbox.dpdk.org/dev/20250222134157.73763253@hermes.local/
- Removed unnecessary casts to (void) in memset calls for better readability.
- Added null checks for pointers in various functions to prevent potential dereferencing of null pointers.
- Enhanced logging messages to provide clearer context
- Updated error handling to ensure proper return values when encountering invalid states.
- Refactored code to improve consistency in variable naming ('if_index' to 'n_intf_no')
- Ensured that memory is properly initialized and freed
* Fix ring queue usage and concurrency problem.
Danylo Vodopianov (18):
net/ntnic: improve logging format specifiers
net/ntnic: remove usless expressions
net/ntnic: remove unused code
net/ntnic: remove usless part of conditional expression
net/ntnic: add error logging for hsh
net/ntnic: add explicitly specificator
net/ntnic: add handle memory allocation failures
net/ntnic: remove redundant initialization
net/ntnic: enhance null checks and assertions
net/ntnic: add return value check
net/ntnic: remove redundant assignments and branching
net/ntnic: rework array usage
net/ntnic: avoid divide by zero
net/ntnic: remove unnecessary void cast
net/ntnic: remove unnecessary memset
net/ntnic: add null verification
net/ntnic: avoid possible deadlock
net/ntnic: fix operation with rte ring queue
Oleksandr Kolomeiets (7):
net/ntnic: remove usage of the variable-length arrays
net/ntnic: handle string truncations when using strlcpy
net/ntnic: replace pragma pack with DPDK defined macros
net/ntnic: remove extra memset
net/ntnic: include all queues into statistics
net/ntnic: avoid misleading variable names
net/ntnic: apply packing to the structure
drivers/net/ntnic/adapter/nt4ga_adapter.c | 7 +-
.../net/ntnic/adapter/nt4ga_stat/nt4ga_stat.c | 4 +-
drivers/net/ntnic/dbsconfig/ntnic_dbsconfig.c | 12 +-
drivers/net/ntnic/include/flow_api_engine.h | 2 +-
drivers/net/ntnic/include/hw_mod_flm_v25.h | 14 +-
drivers/net/ntnic/include/ntnic_virt_queue.h | 4 +-
.../link_mgmt/link_100g/nt4ga_link_100g.c | 6 +-
.../link_agx_100g/nt4ga_agx_link_100g.c | 63 ++--
drivers/net/ntnic/meson.build | 2 -
drivers/net/ntnic/nim/i2c_nim.c | 7 +-
.../core/nt200a0x/reset/nthw_fpga_rst9563.c | 11 -
.../nt200a0x/reset/nthw_fpga_rst_nt200a0x.c | 9 +
.../nthw/core/nt400dxx/nthw_fpga_nt400dxx.c | 3 +-
.../nt400dxx/reset/nthw_fpga_rst_nt400dxx.c | 4 +-
drivers/net/ntnic/nthw/core/nthw_fpga.c | 306 +-----------------
drivers/net/ntnic/nthw/core/nthw_hif.c | 10 +-
drivers/net/ntnic/nthw/core/nthw_iic.c | 7 +-
drivers/net/ntnic/nthw/core/nthw_pcie3.c | 5 +-
drivers/net/ntnic/nthw/core/nthw_phy_tile.c | 5 +-
drivers/net/ntnic/nthw/core/nthw_rpf.c | 5 +-
drivers/net/ntnic/nthw/core/nthw_sdc.c | 8 +-
drivers/net/ntnic/nthw/core/nthw_si5340.c | 5 +-
drivers/net/ntnic/nthw/core/nthw_spi_v3.c | 17 +-
drivers/net/ntnic/nthw/core/nthw_tsm.c | 6 +-
drivers/net/ntnic/nthw/flow_api/flow_api.c | 10 +-
drivers/net/ntnic/nthw/flow_api/flow_group.c | 17 +-
.../net/ntnic/nthw/flow_api/flow_hsh_cfg.c | 8 +-
.../net/ntnic/nthw/flow_api/flow_id_table.c | 3 +-
drivers/net/ntnic/nthw/flow_api/flow_km.c | 10 +-
.../nthw/flow_api/hw_mod/hw_mod_backend.c | 3 +-
.../ntnic/nthw/flow_api/hw_mod/hw_mod_flm.c | 3 -
.../profile_inline/flow_api_hw_db_inline.c | 95 +++---
.../profile_inline/flow_api_profile_inline.c | 93 +++---
.../ntnic/nthw/flow_filter/flow_nthw_cat.c | 4 +-
.../ntnic/nthw/flow_filter/flow_nthw_csu.c | 4 +-
.../ntnic/nthw/flow_filter/flow_nthw_flm.c | 4 +-
.../ntnic/nthw/flow_filter/flow_nthw_hfu.c | 4 +-
.../ntnic/nthw/flow_filter/flow_nthw_hsh.c | 4 +-
.../ntnic/nthw/flow_filter/flow_nthw_ifr.c | 2 +-
.../ntnic/nthw/flow_filter/flow_nthw_info.c | 4 +-
.../net/ntnic/nthw/flow_filter/flow_nthw_km.c | 4 +-
.../ntnic/nthw/flow_filter/flow_nthw_pdb.c | 4 +-
.../ntnic/nthw/flow_filter/flow_nthw_qsl.c | 4 +-
.../ntnic/nthw/flow_filter/flow_nthw_rpp_lr.c | 7 +-
.../ntnic/nthw/flow_filter/flow_nthw_slc_lr.c | 4 +-
.../ntnic/nthw/flow_filter/flow_nthw_tx_cpy.c | 4 +-
.../ntnic/nthw/flow_filter/flow_nthw_tx_ins.c | 4 +-
.../ntnic/nthw/flow_filter/flow_nthw_tx_rpl.c | 4 +-
.../net/ntnic/nthw/model/nthw_fpga_model.c | 11 +-
drivers/net/ntnic/nthw/nthw_rac.c | 32 +-
.../net/ntnic/nthw/ntnic_meter/ntnic_meter.c | 6 +
drivers/net/ntnic/nthw/stat/nthw_stat.c | 5 +-
drivers/net/ntnic/ntnic_ethdev.c | 121 +++----
drivers/net/ntnic/ntnic_filter/ntnic_filter.c | 64 ++--
drivers/net/ntnic/ntnic_vfio.c | 1 -
drivers/net/ntnic/ntnic_xstats/ntnic_xstats.c | 9 +-
56 files changed, 420 insertions(+), 654 deletions(-)
--
2.47.1
next reply other threads:[~2025-04-30 13:49 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-30 13:48 Oleksandr Kolomeiets [this message]
2025-04-30 13:48 ` [PATCH v1 01/25] net/ntnic: remove usage of the variable-length arrays Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 02/25] net/ntnic: handle string truncations when using strlcpy Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 03/25] net/ntnic: replace pragma pack with DPDK defined macros Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 04/25] net/ntnic: remove extra memset Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 05/25] net/ntnic: include all queues into statistics Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 06/25] net/ntnic: avoid misleading variable names Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 07/25] net/ntnic: apply packing to the structure Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 08/25] net/ntnic: improve logging format specifiers Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 09/25] net/ntnic: remove usless expressions Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 10/25] net/ntnic: remove unused code Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 11/25] net/ntnic: remove usless part of conditional expression Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 12/25] net/ntnic: add error logging for hsh Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 13/25] net/ntnic: add explicitly specificator Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 14/25] net/ntnic: add handle memory allocation failures Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 15/25] net/ntnic: remove redundant initialization Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 16/25] net/ntnic: enhance null checks and assertions Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 17/25] net/ntnic: add return value check Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 18/25] net/ntnic: remove redundant assignments and branching Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 19/25] net/ntnic: rework array usage Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 20/25] net/ntnic: avoid divide by zero Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 21/25] net/ntnic: remove unnecessary void cast Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 22/25] net/ntnic: remove unnecessary memset Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 23/25] net/ntnic: add null verification Oleksandr Kolomeiets
2025-04-30 13:48 ` [PATCH v1 24/25] net/ntnic: avoid possible deadlock Oleksandr Kolomeiets
2025-04-30 14:05 ` Stephen Hemminger
2025-04-30 13:48 ` [PATCH v1 25/25] net/ntnic: fix operation with rte ring queue Oleksandr Kolomeiets
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250430134840.402553-1-okl-plv@napatech.com \
--to=okl-plv@napatech.com \
--cc=ckm@napatech.com \
--cc=dev@dpdk.org \
--cc=mko-plv@napatech.com \
--cc=sil-plv@napatech.com \
--cc=stephen@networkplumber.org \
--cc=thomas@monjalon.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).