When sending a burst of output packets on a stopped transmit queue,
the packets are written to a memory mapped address.
On queue start the packets are processed and transmitted by the NIC.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/ntnic_ethdev.c | 4
1 file changed, 4
Perform unmapping in a default container, which is used by queues.
Handle multiple mappings when IOMMU is unoptimized.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/include/ntos_drv.h | 1 +
drivers/net/ntnic/ntnic_ethdev.c | 26 --
drivers/net/ntnic
Handle rx_deferred_start and tx_deferred_start flags
during configuration done in rx_queue_setup and tx_queue_setup,
so that marked queues do not start with dev_start.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/dbsconfig/ntnic_dbsconfig.c | 46 +++
drivers/net
The following functions exported by the driver were stubs
which merely changed the status flags:
* rx_queue_start
* rx_queue_stop
* tx_queue_start
* tx_queue_stop
Proper implementation was added to control queues's state.
Signed-off-by: Oleksandr Kolomeiets
---
dr
This patchset includes:
* feature start/stop queues on HW layer.
* feature deferred start for queues.
* Improvement for memory mappings when IOMMU is unoptimized.
* Improvement for logging
Oleksandr Kolomeiets (4):
net/ntnic: implement start/stop for Rx/Tx
From: Danylo Vodopianov
Avoid usage before check
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/adapter/nt4ga_stat/nt4ga_stat.c | 4 ++--
drivers/net/ntnic/dbsconfig/ntnic_dbsconfig.c | 4 ++--
.../net/ntnic/link_mgmt/link_100g/nt4ga_link_100g.c | 2 +-
.../link_mgmt/l
The function rte_eth_stats_get fills the structure stats with zeroes
before it eventually calls dpdk_stats_collect.
That makes the call to memset inside dpdk_stats_collect redundant.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/ntnic_ethdev.c | 2 --
1 file changed, 2 deletions
From: Danylo Vodopianov
Array usage made more explicitly, avoid pointer arithmetic.
Signed-off-by: Danylo Vodopianov
---
.../ntnic/link_mgmt/link_agx_100g/nt4ga_agx_link_100g.c | 8
drivers/net/ntnic/ntnic_ethdev.c | 2 +-
2 files changed, 5 insertions(+), 5
From: Danylo Vodopianov
Add separate return value verification and logs for function.
Signed-off-by: Danylo Vodopianov
---
.../nthw/core/nt200a0x/reset/nthw_fpga_rst_nt200a0x.c| 9 +
1 file changed, 9 insertions(+)
diff --git
a/drivers/net/ntnic/nthw/core/nt200a0x/reset/nthw_fpga
From: Danylo Vodopianov
Add unsigned long long type to the value to ensure that
the value 1 is explicitly treated as a 64-bit unsigned integer.
Signed-off-by: Danylo Vodopianov
---
.../nthw/flow_api/profile_inline/flow_api_profile_inline.c | 2 +-
1 file changed, 1 insertion(+), 1 deletio
From: Danylo Vodopianov
simplify conditionals and remove redundant checks
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/dbsconfig/ntnic_dbsconfig.c | 3 +-
.../link_agx_100g/nt4ga_agx_link_100g.c | 16 +--
drivers/net/ntnic/nim/i2c_nim.c | 3 +-
.../core/
From: Danylo Vodopianov
Fix CID issue 457736 divide by 0. It was avoided by
adding adittional checking on the return value
for function.
Fixes: effa04693274 ("net/ntnic: add statistics")
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/nthw/stat/nthw_stat.c | 4
1 file changed, 4 i
From: Danylo Vodopianov
Add verification on NULL for variables before use it in the memset.
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/dbsconfig/ntnic_dbsconfig.c | 3 +++
.../link_mgmt/link_100g/nt4ga_link_100g.c | 2 ++
.../net/ntnic/nthw/flow_api/flow_id_table.c| 3
From: Danylo Vodopianov
Remove unused CRC calculation and simplify AVR probe logging.
The condition is always false.
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/nthw/core/nthw_fpga.c | 299 +---
1 file changed, 11 insertions(+), 288 deletions(-)
diff --git a/dri
The macros __rte_packed_begin and __rte_packed_end are used instead
of #pragma pack(1) when structure or union memory should be minimized.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/include/hw_mod_flm_v25.h | 14 ++
drivers/net/ntnic/nthw/core/nthw_spi_v3.c | 15
flow
at the same time.
Signed-off-by: Danylo Vodopianov
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/include/flow_api_engine.h| 2 +-
.../nthw/flow_api/profile_inline/flow_api_profile_inline.c | 7 +++
2 files changed, 4 insertions(+), 5 deletions(-)
diff --git a
From: Danylo Vodopianov
User should call rte_ring_dequeue_zc_elem_finish to complete the
dequeue operation. However this complete step if record absent.
This change rework queue read operation.
Fixes: 96c8249be53e ("net/ntnic: learn flow queue handling")
Signed-off-by: Danylo Vodopianov
---
From: Danylo Vodopianov
Added checks for `calloc` return values to handle memory
allocation failures.
Check for null in rpp_lr_nthw_init
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/nthw/flow_api/flow_group.c | 17 ++--
drivers/net/ntnic/nthw/flow_api/flow_km.c | 4 +++
From: Danylo Vodopianov
Some variables set twice in the code.
Fix host side FEC enablement
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/nim/i2c_nim.c | 2 +-
drivers/net/ntnic/nthw/core/nthw_phy_tile.c | 1 -
drivers/net/ntnic/ntnic_vfio.c | 1 -
3 files chan
In the context of the NTNIC driver,
the variables named if_index stand for the index of the PHY.
However, the term if_index could also refer to the interface index
assigned by the OS.
To mitigate potential confusion these variables were renamed.
Signed-off-by: Oleksandr Kolomeiets
---
drivers
From: Danylo Vodopianov
Remove double if statement branching as far as it has the same fillings.
Signed-off-by: Danylo Vodopianov
---
.../link_agx_100g/nt4ga_agx_link_100g.c | 22 ++-
.../core/nt200a0x/reset/nthw_fpga_rst9563.c | 1 -
drivers/net/ntnic/nthw/nthw_rac.c
From: Danylo Vodopianov
The conditional expressions that always has unchanging state was removed
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/link_mgmt/link_100g/nt4ga_link_100g.c | 2 +-
drivers/net/ntnic/nthw/core/nthw_fpga.c | 4 +---
2 files changed, 2 insertions(
While strlcpy prevents out-of-bounds access,
it allows bugs to remain unnoticed.
If unexcepted truncation took place,
the respective warning message is emitted.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/ntnic_xstats/ntnic_xstats.c | 9 +++--
1 file changed, 7 insertions
From: Danylo Vodopianov
Calling memset before free() has no effect and will be flagged
by security parsing tools as a potential bug. None of these data
structures have sensitive information.
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/nthw/core/nthw_hif.c | 5 +
drivers/
Rename alloced_size to allocated_size.
Rename num_queues_alloced to num_queues_allocated.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/include/hw_mod_backend.h | 2 +-
.../net/ntnic/nthw/flow_api/hw_mod/hw_mod_backend.c | 4 ++--
drivers/net/ntnic/ntnic_ethdev.c
Queues with indices greater than or equal to RTE_ETHDEV_QUEUE_STAT_CNTRS
are ignored when calculating per-queue statistics,
however they should be taken into account for calculating the total.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/ntnic_ethdev.c | 32
From: Danylo Vodopianov
There is no need to cast memset to void.
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/nim/i2c_nim.c | 2 +-
drivers/net/ntnic/nthw/flow_filter/flow_nthw_cat.c| 4 ++--
drivers/net/ntnic/nthw/flow_filter/flow_nthw_csu.c| 4 ++--
dr
From: Danylo Vodopianov
Enhance error logging in hw_db_inline_hsh_deref function to ensure proper
handling of HSH RCP preset failures.
Signed-off-by: Danylo Vodopianov
---
.../nthw/flow_api/profile_inline/flow_api_hw_db_inline.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
di
From: Danylo Vodopianov
Updated logging format specifiers for better consistency
and to match the expected data types
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/adapter/nt4ga_adapter.c | 7 +-
drivers/net/ntnic/dbsconfig/ntnic_dbsconfig.c | 2 +-
.../link_agx_100g/nt4ga_agx_l
The structure virtq_desc should not contain any paddings,
so it has been wrapped with __rte_packed_begin and __rte_packed_end macros.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/include/ntnic_virt_queue.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a
with a stack instead of a heap,
for the same reason it does not require manual memory management.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/meson.build | 2 --
.../flow_api/profile_inline/flow_api_hw_db_inline.c | 13 ++---
.../profile_inline
cation
net/ntnic: avoid possible deadlock
net/ntnic: fix operation with rte ring queue
Oleksandr Kolomeiets (8):
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/n
The macros __rte_packed_begin and __rte_packed_end are used instead
of #pragma pack(1) when structure or union memory should be minimized.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/include/hw_mod_flm_v25.h | 14 ++
drivers/net/ntnic/nthw/core/nthw_spi_v3.c | 15
From: Danylo Vodopianov
Calling memset before free() has no effect and will be flagged
by security parsing tools as a potential bug. None of these data
structures have sensitive information.
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/nthw/core/nthw_hif.c | 5 +
drivers/
From: Danylo Vodopianov
Add verification on NULL for variables before use it in the memset.
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/dbsconfig/ntnic_dbsconfig.c | 3 +++
.../link_mgmt/link_100g/nt4ga_link_100g.c | 2 ++
.../net/ntnic/nthw/flow_api/flow_id_table.c| 3
From: Danylo Vodopianov
User should call rte_ring_dequeue_zc_elem_finish to complete the
dequeue operation. However this complete step if record absent.
This change rework queue read operation.
Fixes: 96c8249be53e ("net/ntnic: learn flow queue handling")
Signed-off-by: Danylo Vodopianov
---
From: Danylo Vodopianov
There is no need to cast memset to void.
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/nim/i2c_nim.c | 2 +-
drivers/net/ntnic/nthw/flow_filter/flow_nthw_cat.c| 4 ++--
drivers/net/ntnic/nthw/flow_filter/flow_nthw_csu.c| 4 ++--
dr
From: Danylo Vodopianov
Sometimes during high flow learn performance two threads
could cause deadlock using queue and mutex.
learn_ignored variable sets when flow learn and gets
when flow removes. Hence, learn_ignore should not be protected
as far as two thread could not access to the same flow
From: Danylo Vodopianov
Fix CID issue 457736 divide by 0. It was avoided by
adding adittional checking on the return value
for function.
Fixes: effa04693274 ("net/ntnic: add statistics")
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/nthw/stat/nthw_stat.c | 4
1 file changed, 4 i
From: Danylo Vodopianov
Array usage made more explicitly, avoid pointer arithmetic.
Signed-off-by: Danylo Vodopianov
---
.../ntnic/link_mgmt/link_agx_100g/nt4ga_agx_link_100g.c | 8
drivers/net/ntnic/ntnic_ethdev.c | 2 +-
2 files changed, 5 insertions(+), 5
From: Danylo Vodopianov
Some variables set twice in the code.
Fix host side FEC enablement
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/nim/i2c_nim.c | 2 +-
drivers/net/ntnic/nthw/core/nthw_phy_tile.c | 1 -
drivers/net/ntnic/ntnic_vfio.c | 1 -
3 files chan
From: Danylo Vodopianov
Remove double if statement branching as far as it has the same fillings.
Signed-off-by: Danylo Vodopianov
---
.../link_agx_100g/nt4ga_agx_link_100g.c | 22 ++-
.../core/nt200a0x/reset/nthw_fpga_rst9563.c | 1 -
drivers/net/ntnic/nthw/nthw_rac.c
From: Danylo Vodopianov
Avoid usage before check
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/adapter/nt4ga_stat/nt4ga_stat.c | 4 ++--
drivers/net/ntnic/dbsconfig/ntnic_dbsconfig.c | 4 ++--
.../net/ntnic/link_mgmt/link_100g/nt4ga_link_100g.c | 2 +-
.../link_mgmt/l
From: Danylo Vodopianov
Add separate return value verification and logs for function.
Signed-off-by: Danylo Vodopianov
---
.../nthw/core/nt200a0x/reset/nthw_fpga_rst_nt200a0x.c| 9 +
1 file changed, 9 insertions(+)
diff --git
a/drivers/net/ntnic/nthw/core/nt200a0x/reset/nthw_fpga
From: Danylo Vodopianov
Updated logging format specifiers for better consistency
and to match the expected data types
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/adapter/nt4ga_adapter.c | 7 +-
drivers/net/ntnic/dbsconfig/ntnic_dbsconfig.c | 2 +-
.../link_agx_100g/nt4ga_agx_l
From: Danylo Vodopianov
Added checks for `calloc` return values to handle memory
allocation failures.
Check for null in rpp_lr_nthw_init
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/nthw/flow_api/flow_group.c | 17 ++--
drivers/net/ntnic/nthw/flow_api/flow_km.c | 4 +++
with a stack instead of a heap,
for the same reason it does not require manual memory management.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/meson.build | 2 --
.../flow_api/profile_inline/flow_api_hw_db_inline.c | 13 ++---
.../profile_inline
From: Danylo Vodopianov
The conditional expressions that always has unchanging state was removed
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/link_mgmt/link_100g/nt4ga_link_100g.c | 2 +-
drivers/net/ntnic/nthw/core/nthw_fpga.c | 4 +---
2 files changed, 2 insertions(
From: Danylo Vodopianov
Add unsigned long long type to the value to ensure that
the value 1 is explicitly treated as a 64-bit unsigned integer.
Signed-off-by: Danylo Vodopianov
---
.../nthw/flow_api/profile_inline/flow_api_profile_inline.c | 2 +-
1 file changed, 1 insertion(+), 1 deletio
From: Danylo Vodopianov
Enhance error logging in hw_db_inline_hsh_deref function to ensure proper
handling of HSH RCP preset failures.
Signed-off-by: Danylo Vodopianov
---
.../nthw/flow_api/profile_inline/flow_api_hw_db_inline.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
di
From: Danylo Vodopianov
simplify conditionals and remove redundant checks
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/dbsconfig/ntnic_dbsconfig.c | 3 +-
.../link_agx_100g/nt4ga_agx_link_100g.c | 16 +--
drivers/net/ntnic/nim/i2c_nim.c | 3 +-
.../core/
From: Danylo Vodopianov
Remove unused CRC calculation and simplify AVR probe logging.
The condition is always false.
Signed-off-by: Danylo Vodopianov
---
drivers/net/ntnic/nthw/core/nthw_fpga.c | 299 +---
1 file changed, 11 insertions(+), 288 deletions(-)
diff --git a/dri
While strlcpy prevents out-of-bounds access,
it allows bugs to remain unnoticed.
If unexcepted truncation took place,
the respective warning message is emitted.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/ntnic_xstats/ntnic_xstats.c | 9 +++--
1 file changed, 7 insertions
In the context of the NTNIC driver,
the variables named if_index stand for the index of the PHY.
However, the term if_index could also refer to the interface index
assigned by the OS.
To mitigate potential confusion these variables were renamed.
Signed-off-by: Oleksandr Kolomeiets
---
drivers
The structure virtq_desc should not contain any paddings,
so it has been wrapped with __rte_packed_begin and __rte_packed_end macros.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/include/ntnic_virt_queue.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a
The function rte_eth_stats_get fills the structure stats with zeroes
before it eventually calls dpdk_stats_collect.
That makes the call to memset inside dpdk_stats_collect redundant.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/ntnic_ethdev.c | 2 --
1 file changed, 2 deletions
Queues with indices greater than or equal to RTE_ETHDEV_QUEUE_STAT_CNTRS
are ignored when calculating per-queue statistics,
however they should be taken into account for calculating the total.
Signed-off-by: Oleksandr Kolomeiets
---
drivers/net/ntnic/ntnic_ethdev.c | 32
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
:
testpmd> flow create 0 group 1 pattern eth / end actions drop / end
Flow rule #0 created
testpmd> flow update 0 0 actions queue index 1 / end
Flow rule #0 updated with new actions
testpmd> flow destroy 0 rule 0
Flow rule #0 destroyed
Signed-off-by: Oleksandr Ko
:
testpmd> flow create 0 group 1 pattern eth / end actions drop / end
Flow rule #0 created
testpmd> flow update 0 0 actions queue index 1 / end
Flow rule #0 updated with new actions
testpmd> flow destroy 0 rule 0
Flow rule #0 destroyed
Signed-off-by: Oleksandr Ko
:
testpmd> flow create 0 group 1 pattern eth / end actions drop / end
Flow rule #0 created
testpmd> flow update 0 0 actions queue index 1 / end
Flow rule #0 updated with new actions
testpmd> flow destroy 0 rule 0
Flow rule #0 destroyed
Signed-off-by: Oleksandr Ko
__
From: Dariusz Sosnowski
Sent: Monday, February 5, 2024 9:18 PM
To: NBU-Contact-Thomas Monjalon (EXTERNAL) ; Mykola
Kostenok ; Christian Koue Muf ;
Oleksandr Kolomeiets
Cc: aman.deep.si...@intel.com ;
yuying.zh...@intel.com ; dev@dpdk.org ;
Ori Kam
Subject: RE: [PATCH v2] app/testpmd: support upd
stroying a flow rule:
testpmd> flow create 0 group 1 pattern eth / end actions drop / end
Flow rule #0 created
testpmd> flow actions_update 0 0 actions queue index 1 / end
Flow rule #0 updated with new actions
testpmd> flow destroy 0 rule 0
Flow rule #0 destroyed
Signed
stroying a flow rule:
testpmd> flow create 0 group 1 pattern eth / end actions drop / end
Flow rule #0 created
testpmd> flow actions_update 0 0 actions queue index 1 / end
Flow rule #0 updated with new actions
testpmd> flow destroy 0 rule 0
Flow rule #0 destroyed
Signed
64 matches
Mail list logo