[PATCH] app/testpmd: fix set cores list string size

2025-07-08 Thread Dengdui Huang
The cmdline_fixed_string_t has a length of only 128, which will become insufficient when there are many cores, so it should be replaced with a cmdline_multi_string_t of larger capacity. Fixes: af75078fece3 ("first public release") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang ---

[PATCH] net: support VLAN stacking packet type parsing

2025-07-03 Thread Dengdui Huang
The current rte_net_get_ptype() only supports parsing packets with one 0x8100 VLAN tag or two 0x88a8 VLAN tags. This patch extends it to support parsing packets with two 0x8100 VLAN tags. Signed-off-by: Dengdui Huang --- lib/net/rte_net.c | 34 ++ lib/net

[PATCH v3 3/6] net/hns3: refactor DCB module code

2025-07-01 Thread Dengdui Huang
From: Chengwen Feng The DCB-related fields span in multiple structures, this patch moves them into struct hns3_dcb_info. Signed-off-by: Chengwen Feng Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_dcb.c | 13 +-- drivers/net/hns3/hns3_ethdev.c| 38

[PATCH v3 6/6] net/hns3: VF support multi-TCs configure

2025-07-01 Thread Dengdui Huang
rte_eth_dcb_tx_conf) must be the same as that of the PF. 2. VF does not support RTE_ETH_DCB_PFC_SUPPORT configuration. Signed-off-by: Chengwen Feng Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_dcb.c | 106 drivers/net/hns3/hns3_dcb.h | 4 + drivers/net/hns3

[PATCH v3 4/6] net/hns3: VF support parse max TC number

2025-07-01 Thread Dengdui Huang
support dump the TC info. Signed-off-by: Chengwen Feng Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_dump.c | 2 ++ drivers/net/hns3/hns3_ethdev_vf.c | 1 + drivers/net/hns3/hns3_mbx.h | 2 +- 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/net/hns3

[PATCH v2 0/6] net/hns3: VF support multi-TCs

2025-07-01 Thread Dengdui Huang
This patchset adds the VF multi-TCs feature. --- v2: Use the macros __rte_packed_begin and __rte_packed_end instead of #pragma pack(). Chengwen Feng (6): net/hns3: fix VF fail to config queue TC net/hns3: remove duplicate struct field net/hns3: refactor DCB module code net/hns3: VF suppo

[PATCH v3 5/6] net/hns3: VF support discover multi-TCs capability

2025-07-01 Thread Dengdui Huang
: Dengdui Huang --- drivers/net/hns3/hns3_cmd.c | 5 - drivers/net/hns3/hns3_cmd.h | 2 ++ drivers/net/hns3/hns3_dump.c | 3 ++- drivers/net/hns3/hns3_ethdev.h| 1 + drivers/net/hns3/hns3_ethdev_vf.c | 33 +++ drivers/net/hns3/hns3_mbx.h | 7

[PATCH v3 1/6] net/hns3: fix VF fail to config queue TC

2025-07-01 Thread Dengdui Huang
ngwen Feng Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_cmd.h | 8 drivers/net/hns3/hns3_rxtx.c | 26 +- 2 files changed, 29 insertions(+), 5 deletions(-) diff --git a/drivers/net/hns3/hns3_cmd.h b/drivers/net/hns3/hns3_cmd.h index 4d707c13b2..e21a2b6

[PATCH v3 2/6] net/hns3: remove duplicate struct field

2025-07-01 Thread Dengdui Huang
From: Chengwen Feng The struct hns3_hw and hns3_hw.dcb_info both has num_tc field, their meanings are the same, to ensure code readability, remove the num_tc field of struct hns3_hw. Signed-off-by: Chengwen Feng Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_dcb.c | 44

[PATCH v3 0/6] net/hns3: VF support multi-TCs

2025-07-01 Thread Dengdui Huang
This patchset adds the VF multi-TCs feature. --- v2: Use the macros __rte_packed_begin and __rte_packed_end instead of #pragma pack(). v3: Fix checkpatch warnings: line length of 102 exceeds 100 columns. Chengwen Feng (6): net/hns3: fix VF fail to config queue TC net/hns3: remove duplicate

[PATCH v2 5/6] net/hns3: VF support discover multi-TCs capability

2025-07-01 Thread Dengdui Huang
From: Chengwen Feng The VF multi-TCs feature depends on firmware and PF driver, the capability was set when: 1) Firmware report VF multi-TCs flag. 2) PF driver report VF multi-TCs flag. 3) PF driver support query multi-TCs info mailbox message. Signed-off-by: Chengwen Feng --- drivers/net/hns3

[PATCH v2 2/6] net/hns3: remove duplicate struct field

2025-06-30 Thread Dengdui Huang
From: Chengwen Feng The struct hns3_hw and hns3_hw.dcb_info both has num_tc field, their meanings are the same, to ensure code readability, remove the num_tc field of struct hns3_hw. Signed-off-by: Chengwen Feng --- drivers/net/hns3/hns3_dcb.c | 44 --- driver

[PATCH v2 6/6] net/hns3: VF support multi-TCs configure

2025-06-30 Thread Dengdui Huang
From: Chengwen Feng If VF has the multi-TCs capability, then application could configure the multi-TCs feature through the DCB interface. Because VF does not have its own ETS and PFC components, the constraints are as follows: 1. The DCB configuration (struct rte_eth_dcb_rx_conf and rte_eth_d

[PATCH v2 4/6] net/hns3: VF support parse max TC number

2025-06-30 Thread Dengdui Huang
From: Chengwen Feng The mailbox message HNS3_MBX_GET_BASIC_INFO can obtain the maximum number of TCs of the device. The VF does not support multiple TCs, therefore, this field is not saved. Now the VF needs to support multiple TCs, therefore, this field needs to be saved. This commit also suppo

[PATCH v2 1/6] net/hns3: fix VF fail to config queue TC

2025-06-30 Thread Dengdui Huang
From: Chengwen Feng The VF cannot configure the mapping of queue to TC by directly writing the register. Instead, the mapping must be modified by using firmware command. Fixes: bba636698316 ("net/hns3: support Rx/Tx and related operations") Cc: sta...@dpdk.org Signed-off-by: Chengwen Feng ---

[PATCH v2 3/6] net/hns3: refactor DCB module code

2025-06-30 Thread Dengdui Huang
From: Chengwen Feng The DCB-related fields span in multiple structures, this patch moves them into struct hns3_dcb_info. Signed-off-by: Chengwen Feng --- drivers/net/hns3/hns3_dcb.c | 13 +-- drivers/net/hns3/hns3_ethdev.c| 38 +++ drivers/net/hns3

[PATCH 0/2] fix parse tunnel packet ptyoe

2025-06-16 Thread Dengdui Huang
Dengdui Huang (2): net: fix parse the tunnel length of tunnel with UDP app/testpmd: fix obtain inner info of tunnel packet app/test-pmd/csumonly.c | 6 +++--- lib/net/rte_net.c | 4 lib/net/rte_net.h | 2 ++ 3 files changed, 9 insertions(+), 3 deletions(-) -- 2.33.0

[PATCH 2/2] app/testpmd: fix obtain inner info of tunnel packet

2025-06-16 Thread Dengdui Huang
ned-off-by: Dengdui Huang --- app/test-pmd/csumonly.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/test-pmd/csumonly.c b/app/test-pmd/csumonly.c index 203af35cf0..d355dbd8c0 100644 --- a/app/test-pmd/csumonly.c +++ b/app/test-pmd/csumonly.c @@ -712,

[PATCH 1/2] net: fix parse the tunnel length of tunnel with UDP

2025-06-16 Thread Dengdui Huang
t;net: add tunnel packet type parsing") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- lib/net/rte_net.c | 4 lib/net/rte_net.h | 2 ++ 2 files changed, 6 insertions(+) diff --git a/lib/net/rte_net.c b/lib/net/rte_net.c index 098999e71e..44fb6c0f51 100644 --- a/lib/net/rte_net.c

[PATCH 3/6] net/hns3: refactor DCB module code

2025-06-11 Thread Dengdui Huang
From: Chengwen Feng The DCB-related fields span in multiple structures, this patch moves them into struct hns3_dcb_info. Signed-off-by: Chengwen Feng Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_dcb.c | 13 +-- drivers/net/hns3/hns3_ethdev.c| 38

[PATCH 5/6] net/hns3: VF support discover multi-TCs capability

2025-06-11 Thread Dengdui Huang
: Dengdui Huang --- drivers/net/hns3/hns3_cmd.c | 5 - drivers/net/hns3/hns3_cmd.h | 2 ++ drivers/net/hns3/hns3_dump.c | 3 ++- drivers/net/hns3/hns3_ethdev.h| 1 + drivers/net/hns3/hns3_ethdev_vf.c | 33 +++ drivers/net/hns3/hns3_mbx.h | 7

[PATCH 4/6] net/hns3: VF support parse max TC number

2025-06-11 Thread Dengdui Huang
support dump the TC info. Signed-off-by: Chengwen Feng Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_dump.c | 2 ++ drivers/net/hns3/hns3_ethdev_vf.c | 1 + drivers/net/hns3/hns3_mbx.h | 2 +- 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/net/hns3

[PATCH 6/6] net/hns3: VF support multi-TCs configure

2025-06-11 Thread Dengdui Huang
rte_eth_dcb_tx_conf) must be the same as that of the PF. 2. VF does not support RTE_ETH_DCB_PFC_SUPPORT configuration. Signed-off-by: Chengwen Feng Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_dcb.c | 106 drivers/net/hns3/hns3_dcb.h | 4 + drivers/net/hns3

[PATCH 1/6] net/hns3: fix VF fail to config queue TC

2025-06-11 Thread Dengdui Huang
ngwen Feng Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_cmd.h | 8 drivers/net/hns3/hns3_rxtx.c | 26 +- 2 files changed, 29 insertions(+), 5 deletions(-) diff --git a/drivers/net/hns3/hns3_cmd.h b/drivers/net/hns3/hns3_cmd.h index 4d707c13b2..e21a2b6

[PATCH 0/6] net/hns3: VF support multi-TCs

2025-06-11 Thread Dengdui Huang
This patchset adds the VF multi-TCs feature. Chengwen Feng (6): net/hns3: fix VF fail to config queue TC net/hns3: remove duplicate struct field net/hns3: refactor DCB module code net/hns3: VF support parse max TC number net/hns3: VF support discover multi-TCs capability net/hns3: VF s

[PATCH 2/6] net/hns3: remove duplicate struct field

2025-06-11 Thread Dengdui Huang
From: Chengwen Feng The struct hns3_hw and hns3_hw.dcb_info both has num_tc field, their meanings are the same, to ensure code readability, remove the num_tc field of struct hns3_hw. Signed-off-by: Chengwen Feng Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_dcb.c | 44

[PATCH 2/3] net/hns3: fix can't use vector for Tx when not set fast free

2025-06-09 Thread Dengdui Huang
Currently, select Tx vector algorithm only when tx_offload is RTE_ETH_TX_OFFLOAD_MBUF_FAST_FREE. Actually, this algorithm already supported the case that tx_offload isn't fast free. Fixes: e31f123db06b ("net/hns3: support NEON Tx") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huan

[PATCH 0/3] net/hns3: bugfix for hns3

2025-06-09 Thread Dengdui Huang
This patchset fixes some bugs. Dengdui Huang (3): net/hns3: fix the hardware GRO function is abnormal net/hns3: fix can't use vector for Tx when not set fast free net/hns3: fix can't use vector for Rx when set VLAN filter drivers/net/hns3/hns3_rxtx.c | 12 d

[PATCH 1/3] net/hns3: fix the hardware GRO function is abnormal

2025-06-09 Thread Dengdui Huang
: d14c995b775a ("net/hns3: check Rx DMA address alignmnent") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_rxtx.c | 12 1 file changed, 12 insertions(+) diff --git a/drivers/net/hns3/hns3_rxtx.c b/drivers/net/hns3/hns3_rxtx.c index bde46733b0..

[PATCH 3/3] net/hns3: fix can't use vector for Rx when set VLAN filter

2025-06-09 Thread Dengdui Huang
Currently, When RTE_ETH_RX_OFFLOAD_VLAN_FILTER offload is set, driver wouldn't select Rx vector algorithm. Actually, this algorithm support it, so open it. Fixes: a3d4f4d291d7 ("net/hns3: support NEON Rx") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- drivers/net/hns3/

[PATCH v5] net: fix GTP packet parsing

2025-06-03 Thread Dengdui Huang
ned-off-by: Dengdui Huang Acked-by: Jie Hai --- lib/net/rte_net.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/lib/net/rte_net.c b/lib/net/rte_net.c index 1264f33d61..098999e71e 100644 --- a/lib/net/rte_net.c +++ b/lib/net/rte_net.c @@ -231,7 +231,13 @@ ptype_tunne

[PATCH v4 3/3] app/testpmd: fix obtain inner info of tunnel packet

2025-05-22 Thread Dengdui Huang
l2_len for tunneling packets should contain Outer_L4_len. Additionally, the current offset used for the inner Ethernet header is incorrect. This patch fixes these issues. Fixes: 76730c7b9b5a ("app/testpmd: use packet type parsing API") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang

[PATCH v4 1/3] net: fix GTP packet parsing

2025-05-22 Thread Dengdui Huang
ned-off-by: Dengdui Huang Acked-by: Jie Hai --- lib/net/rte_net.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/lib/net/rte_net.c b/lib/net/rte_net.c index be24690fdf..1771588a09 100644 --- a/lib/net/rte_net.c +++ b/lib/net/rte_net.c @@ -231,7 +231,13 @@ ptype_tunne

[PATCH v4 2/3] net: fix parse the tunnel length of tunnel packet with UDP

2025-05-22 Thread Dengdui Huang
Currently, the tunnel length info is not available when get the tunnel packet type with UDP port. This patch adds the parsing of the tunnel length info. Fixes: 64ed7f854cf4 ("net: add tunnel packet type parsing") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- lib/net/rte

[PATCH v3 4/4] app/testpmd: fix obtain inner info of tunnel packet

2025-05-16 Thread Dengdui Huang
l2_len for tunneling packets should contain Outer_L4_len. Additionally, the current offset used for the inner Ethernet header is incorrect. This patch fixes these issues. Fixes: 76730c7b9b5a ("app/testpmd: use packet type parsing API") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang

[PATCH v3 1/4] net: fix GTP packet parsing

2025-05-16 Thread Dengdui Huang
ned-off-by: Dengdui Huang Acked-by: Jie Hai --- lib/net/rte_net.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/lib/net/rte_net.c b/lib/net/rte_net.c index be24690fdf..1771588a09 100644 --- a/lib/net/rte_net.c +++ b/lib/net/rte_net.c @@ -231,7 +231,13 @@ ptype_tunne

[PATCH v3 0/4] bugfix about parse tunnel packet with UDP

2025-05-16 Thread Dengdui Huang
Currently, there are some issues with testpmd and get ptype API in parsing tunnel packets, and this patchset is fix it. Dengdui Huang (4): net: fix GTP packet parsing net: fix parse the tunnel length of tunnel packet with UDP net: fix GENEVE packet parsing app/testpmd: fix obtain inner

[PATCH v3 2/4] net: fix parse the tunnel length of tunnel packet with UDP

2025-05-16 Thread Dengdui Huang
Currently, the tunnel length info is not available when get the tunnel packet type with UDP port. This patch adds the parsing of the tunnel length info. Fixes: 64ed7f854cf4 ("net: add tunnel packet type parsing") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- lib/net/rte

[PATCH v3 3/4] net: fix GENEVE packet parsing

2025-05-16 Thread Dengdui Huang
When the GENEVE packet is processed, the offset is not changed correctly. As a result, the inner packet is incorrectly parsed. This patch fixes it. Fixes: 64ed7f854cf4 ("net: add tunnel packet type parsing") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- lib/net/rte_net.c | 2

[PATCH v5 2/2] net/hns3: fix Rx packet without CRC data

2025-05-16 Thread Dengdui Huang
to recaculate packet CRC for this rare scenarios. In addition, to avoid impacting performance, KEEP_CRC is not supported when NEON or SVE algorithm is used. Fixes: 8973d7c4ca12 ("net/hns3: support keeping CRC") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang Acked-by: Huisong Li Ack

[PATCH v5 1/2] net/hns3: fix cannot look the CRC data

2025-05-16 Thread Dengdui Huang
rg Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_rxtx.c | 13 + 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/drivers/net/hns3/hns3_rxtx.c b/drivers/net/hns3/hns3_rxtx.c index bb7ffee12c..49b6f16ccd 100644 --- a/drivers/net/hns3/hns3_rxtx.c +++ b/driver

[PATCH v5 0/2] bugfix about KEEP CRC offload

2025-05-16 Thread Dengdui Huang
This patchset fixes two bugs related to the keep_crc feature in hns3. Additionally, as previously discussed, the pkt_len field in mbuf does not include the length of the CRC data, which is also consistent with the behavior of most drivers. Dengdui Huang (2): net/hns3: fix cannot look the CRC

[PATCH v2] net: fix GTP packet parsing

2025-04-17 Thread Dengdui Huang
ned-off-by: Dengdui Huang Acked-by: Jie Hai --- lib/net/rte_net.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/lib/net/rte_net.c b/lib/net/rte_net.c index be24690fdf..1771588a09 100644 --- a/lib/net/rte_net.c +++ b/lib/net/rte_net.c @@ -231,7 +231,13 @@ ptype_tunne

[PATCH] net: fix GTP packet parsing

2025-04-11 Thread Dengdui Huang
After parsing the GTP packet header, the next protocol type should be converted from RTE_GTP_TYPE_IPV4/IPV6 to RTE_ETHER_TYPE_IPV4/IPV6. Otherwise, the next protocol cannot be parsed. Fixes: 64ed7f854cf4 ("net: add tunnel packet type parsing") Cc: sta...@dpdk.org Signed-off-by: Den

[PATCH 2/7] net/hns3: fix memory leakage in failure path

2025-04-08 Thread Dengdui Huang
") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_regs.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/hns3/hns3_regs.c b/drivers/net/hns3/hns3_regs.c index 8a6ddbfe8c..5c74f9ae2e 100644 --- a/drivers/net/hns3/hns3_regs.c +++

[RFC 0/1] support ThreadSanitizer

2025-04-08 Thread Dengdui Huang
insufficient and the DPDK cannot be initialized. I fixed it by changing the value of the macro RTE_MAX_MEM_MB, but I know that's not a good idea. Suggestions are welcome. Dengdui Huang (1): build: support ThreadSanitizer config/meson.build | 14 ++ 1 file changed, 14 inser

[RFC 1/1] build: support ThreadSanitizer

2025-04-08 Thread Dengdui Huang
and can be enabled via a meson option: -Db_sanitize=thread. Signed-off-by: Dengdui Huang --- config/meson.build | 14 ++ 1 file changed, 14 insertions(+) diff --git a/config/meson.build b/config/meson.build index f31fef216c..dca1e2b5a4 100644 --- a/config/meson.build +++ b/config

[PATCH 5/7] net/hns3: fix incorrect failed rollback

2025-04-08 Thread Dengdui Huang
When the port is started, if the Tx queue fails to be started, the map interrupt should be rolled back. Fixes: fdfde7a4a0f8 ("net/hns3: fix mbuf leakage") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_ethdev.c | 4 +++- 1 file changed, 3 insertions(+),

[PATCH 1/7] net/hns3: fix variable overflow

2025-04-08 Thread Dengdui Huang
The number of interrupt vector may exceed the range of uint8_t. So hns3_unmap_rx_interrupt() should use uint16_t for 'vec' variable. Fixes: 02a7b55657b2 ("net/hns3: support Rx interrupt") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_commo

[PATCH 7/7] net/hns3: fix unrelease some resources on reset case

2025-04-08 Thread Dengdui Huang
Some resources, like, unmapping Rx interrupt, doesn't perform when execute dev_stop on reset. This will lead to other issues. Fixes: 2790c6464725 ("net/hns3: support device reset") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_ethdev.c | 19 +++

[PATCH 4/7] net/hns3: fix memory leakage for indirect action

2025-04-08 Thread Dengdui Huang
/hns3: support indirect counter flow action") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_flow.c | 41 drivers/net/hns3/hns3_flow.h | 9 ++-- 2 files changed, 25 insertions(+), 25 deletions(-) diff --git a/driver

[PATCH 6/7] net/hns3: fix divide by zero

2025-04-08 Thread Dengdui Huang
Driver may encounter divide-by-zero if the total_tqps_num and rss_size_max in hw structure from firmware are zero. So add some verification to them. Fixes: d51867db65c1 ("net/hns3: add initialization") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- drivers/net/hns3/hns3_eth

[PATCH 3/7] net/hns3: fix extra waiting for link up

2025-04-08 Thread Dengdui Huang
If the link auto-negotiation of the NIC is disabled, or the flow control auto-negotiation is not supported, it's unnecessary to wait for link establishment. Fixes: 1f411e31a826 ("net/hns3: support flow control autoneg for copper port") Cc: sta...@dpdk.org Signed-off-by

[PATCH 0/7] net/hns3: bugfix for hns3

2025-04-08 Thread Dengdui Huang
This patchset fixes some bugs. Dengdui Huang (7): net/hns3: fix variable overflow net/hns3: fix memory leakage in failure path net/hns3: fix extra waiting for link up net/hns3: fix memory leakage for indirect action net/hns3: fix incorrect failed rollback net/hns3: fix divide by zero

[PATCH v3 3/3] app/dma-perf: fix infinite loop

2025-04-05 Thread Dengdui Huang
When a core that is not used by the rte is specified in the config for testing, the problem of infinite loop occurs. This patch fix it by adding a check for lcore_id. Fixes: 623dc9364dc6 ("app/dma-perf: introduce DMA performance test") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang

[PATCH v2] mem: fix infinite loop

2025-04-04 Thread Dengdui Huang
ned-off-by: Dengdui Huang Acked-by: Dmitry Kozlyuk --- lib/eal/common/eal_common_memory.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/lib/eal/common/eal_common_memory.c b/lib/eal/common/eal_common_memory.c index a185e0b580..0c997201bd 100644 --- a/lib/

[PATCH v2 1/2] eal: fix uncheck worker ID

2025-04-04 Thread Dengdui Huang
The worker_id may come from user input. So it is necessary to verify it. Fixes: a95d70547c57 ("eal: factorize lcore main loop") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- lib/eal/common/eal_common_launch.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/

[PATCH v2] mem: fix infinite loop

2025-04-02 Thread Dengdui Huang
ned-off-by: Dengdui Huang Acked-by: Dmitry Kozlyuk --- lib/eal/common/eal_common_memory.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/lib/eal/common/eal_common_memory.c b/lib/eal/common/eal_common_memory.c index a185e0b580..0c997201bd 100644 --- a/lib/

[PATCH v3 1/3] eal: fix uncheck lcore ID

2025-04-02 Thread Dengdui Huang
The worker_id may come from user input. So it is necessary to verify it. Fixes: a95d70547c57 ("eal: factorize lcore main loop") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- lib/eal/common/eal_common_launch.c | 9 + 1 file changed, 9 insertions(+) diff --git a/lib/

[PATCH] mem: fix infinite loop

2025-04-02 Thread Dengdui Huang
When the process address space is insufficient, mmap will fail, which will cause an infinite loop. This pathc fix it. Fixes: c4b89ecb64ea ("eal: introduce memory management wrappers") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- lib/eal/common/eal_common_memory.c | 8 ++

[PATCH v3 2/3] eal: fix unckeck pipe

2025-04-02 Thread Dengdui Huang
The communication pipe may be unavailable, for example, when the lcore role is ROLE_OFF or ROLE_NON_EAL. So check whether the pipe is available before using it. Fixes: a95d70547c57 ("eal: factorize lcore main loop") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- li

[PATCH v3 0/3] fix the problem of dma-perf infinite loop

2025-04-02 Thread Dengdui Huang
After CPU isolation is configured, an infinite loop occurs when dma-perf is executed using the default config file. This patchset fix it by adding lcore ID checks and pipe checks. Dengdui Huang (3): eal: fix uncheck lcore ID eal: fix unckeck pipe app/dma-perf: fix infinite loop app/test

[PATCH v2 0/2] fix the problem of dma-perf infinite loop

2025-03-27 Thread Dengdui Huang
After CPU isolation is configured, an infinite loop occurs when dma-perf is executed using the default config file. This patchset fix it. Dengdui Huang (2): eal: fix uncheck worker ID app/dma-perf: fix infinite loop app/test-dma-perf/main.c | 8 +++- lib/eal/common

[PATCH 2/2] app/dma-perf: fix infinite loop

2025-03-27 Thread Dengdui Huang
When a core that is not used by the rte is specified in the config for testing, the problem of infinite loop occurs. This patch fix it by adding a check for lcore_id. Fixes: 623dc9364dc6 ("app/dma-perf: introduce DMA performance test") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang

[PATCH v2 2/2] app/dma-perf: fix infinite loop

2025-03-27 Thread Dengdui Huang
When a core that is not used by the rte is specified in the config for testing, the problem of infinite loop occurs. This patch fix it by adding a check for lcore_id. Fixes: 623dc9364dc6 ("app/dma-perf: introduce DMA performance test") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang

[PATCH 1/2] eal: fix uncheck worker ID

2025-03-27 Thread Dengdui Huang
The worker_id may come from user input. So it is necessary to verify it. Fixes: a95d70547c57 ("eal: factorize lcore main loop") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- lib/eal/common/eal_common_launch.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/

[PATCH] app/dma-perf: fix infinite loop

2025-03-27 Thread Dengdui Huang
When a core that is not used by the rte is specified in the config for testing, the problem of infinite loop occurs. This patch fix it by adding a check for lcore_id. Fixes: 623dc9364dc6 ("app/dma-perf: introduce DMA performance test") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang

[PATCH 2/2] app/dma-perf: fix infinite loop

2025-03-24 Thread Dengdui Huang
p/dma-perf: support config per device") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- app/test-dma-perf/benchmark.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/test-dma-perf/benchmark.c b/app/test-dma-perf/benchmark.c index 6d617ea200..351c1c966e 100644

[PATCH 0/2] fix the problem of dma-perf infinite loop

2025-03-20 Thread Dengdui Huang
After CPU isolation is configured, an infinite loop occurs when dma-perf is executed using the default config file. This patchset fix it. Dengdui Huang (2): eal: fix wake a incorrect lcore app/dma-perf: fix infinite loop app/test-dma-perf/benchmark.c | 5 - lib/eal/unix

[PATCH 1/2] eal: fix wake a incorrect lcore

2025-03-20 Thread Dengdui Huang
If the core is not used in the rte, we can't wake it up to work. The worker_id may come from user input. So it is necessary to verify it. Fixes: a95d70547c57 ("eal: factorize lcore main loop") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- lib/eal/unix/eal_unix_thread.c |

[PATCH v2] app/procinfo: add xstats parameter to hide zero

2025-02-06 Thread Dengdui Huang
-off-by: Dengdui Huang Acked-by: Chengwen Feng Acked-by: Stephen Hemminger --- app/proc-info/main.c | 20 ++-- doc/guides/tools/proc_info.rst | 7 --- 2 files changed, 18 insertions(+), 9 deletions(-) diff --git a/app/proc-info/main.c b/app/proc-info/main.c index

[PATCH] app/procinfo: add xstats parameter to hide zero

2025-01-24 Thread Dengdui Huang
-off-by: Dengdui Huang Acked-by: Chengwen Feng --- app/proc-info/main.c | 20 ++-- doc/guides/tools/proc_info.rst | 7 --- 2 files changed, 18 insertions(+), 9 deletions(-) diff --git a/app/proc-info/main.c b/app/proc-info/main.c index e1272164b1..cc0f71c229 100644

[PATCH] mbuf: add packet offload Rx flag for keep CRC

2025-01-24 Thread Dengdui Huang
://inbox.dpdk.org/dev/20240206011030.2007689-1-haij...@huawei.com/ Signed-off-by: Dengdui Huang --- lib/mbuf/rte_mbuf.c | 3 ++- lib/mbuf/rte_mbuf_core.h | 8 +++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/lib/mbuf/rte_mbuf.c b/lib/mbuf/rte_mbuf.c index 559d5ad8a7..c828200ea1

[PATCH] examples/l3fwd: add option to set refetch offset

2025-01-10 Thread Dengdui Huang
only in the main loop. Signed-off-by: Dengdui Huang --- examples/l3fwd/l3fwd.h | 6 ++- examples/l3fwd/l3fwd_acl_scalar.h| 6 +-- examples/l3fwd/l3fwd_em.h| 18 - examples/l3fwd/l3fwd_em_hlm.h| 9 +++-- examples/l3fwd/l3fwd_em_sequential.h | 60

[PATCH] examples/l3fwd: optimize packet prefetch

2024-12-24 Thread Dengdui Huang
, prefetching all packets before processing can achieve better performance. Signed-off-by: Dengdui Huang --- examples/l3fwd/l3fwd_lpm_neon.h | 42 - 1 file changed, 5 insertions(+), 37 deletions(-) diff --git a/examples/l3fwd/l3fwd_lpm_neon.h b/examples/l3fwd

[PATCH v6 14/14] test: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- app/test/test_bpf.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/test/test_bpf.c b/app/test/test_bpf.c index 90e10d7d2c..2f9412e28c

[PATCH v6 13/14] app/dumpcap: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- app/dumpcap/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/dumpcap/main.c b/app/dumpcap/main.c index 3d3c0dbc66..6b122862af 100644 --- a

[PATCH v6 05/14] common/mlx5: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- drivers/common/mlx5/linux/mlx5_nl.c | 10 +- drivers/common/mlx5/mlx5_common.c | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a

[PATCH v6 09/14] net/memif: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- drivers/net/memif/rte_eth_memif.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/memif/rte_eth_memif.c b/drivers/net/memif

[PATCH v6 12/14] net/tap: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- drivers/net/tap/rte_eth_tap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/tap/rte_eth_tap.c b/drivers/net/tap/rte_eth_tap.c index

[PATCH v6 11/14] net/mlx5: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- drivers/net/mlx5/hws/mlx5dr_matcher.c | 2 +- drivers/net/mlx5/linux/mlx5_ethdev_os.c | 22 +++--- drivers/net/mlx5/linux/mlx5_os.c | 16

[PATCH v6 07/14] net/bonding: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- drivers/net/bonding/rte_eth_bond_flow.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/bonding/rte_eth_bond_flow.c b/drivers/net

[PATCH v6 08/14] net/failsafe: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- drivers/net/failsafe/failsafe.c | 2 +- drivers/net/failsafe/failsafe_eal.c | 2 +- drivers/net/failsafe/failsafe_flow.c | 4 ++-- 3 files changed, 4 insertions

[PATCH v6 03/14] pdump: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- lib/pdump/rte_pdump.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/pdump/rte_pdump.c b/lib/pdump/rte_pdump.c index 679c3dd0b5..55c6eeaa36 100644

[PATCH v6 06/14] net/af_xdp: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- drivers/net/af_xdp/rte_eth_af_xdp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/af_xdp/rte_eth_af_xdp.c b/drivers/net/af_xdp

[PATCH v6 04/14] bus/vdev: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- drivers/bus/vdev/vdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/bus/vdev/vdev.c b/drivers/bus/vdev/vdev.c index ec7abe7cda..299f8c2873

[PATCH v6 10/14] net/mlx4: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- drivers/net/mlx4/mlx4.c| 2 +- drivers/net/mlx4/mlx4_ethdev.c | 18 +- drivers/net/mlx4/mlx4_rxq.c| 4 ++-- drivers/net/mlx4/mlx4_txq.c

[PATCH v6 00/14] use rte_strerror() for rte_errno

2024-11-14 Thread Dengdui Huang
used as an argument to any function and the checkpatch script should not return an error, so I didn't do that. Dengdui Huang (14): eal: fix use rte errno for libc function eal: use rte strerror pdump: use rte strerror bus/vdev: use rte strerror common/mlx5: use rte strerror net/a

[PATCH v6 01/14] eal: fix use rte errno for libc function

2024-11-14 Thread Dengdui Huang
In the libc function, rte_errno is not assigned a value. Therefore, errno should be used instead of it. Fixes: c4b89ecb64ea ("eal: introduce memory management wrappers") Cc: sta...@dpdk.org Signed-off-by: Dengdui Huang --- lib/eal/unix/eal_unix_memory.c | 2 +- 1 file changed, 1

[PATCH v6 02/14] eal: use rte strerror

2024-11-14 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang --- lib/eal/linux/eal_dev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/eal/linux/eal_dev.c b/lib/eal/linux/eal_dev.c index e63f24d108..95b1d02c9f

[PATCH v5 46/52] net/tap: use rte strerror

2024-11-04 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang Acked-by: Chengwen Feng Acked-by: Morten Brørup Acked-by: Huisong Li --- drivers/net/tap/rte_eth_tap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git

[PATCH v5 39/52] net/mlx4: replace strerror with reentrant version

2024-11-04 Thread Dengdui Huang
The function strerror() is insecure in a multi-thread environment. This patch uses strerror_r() to replace it. Signed-off-by: Dengdui Huang Acked-by: Chengwen Feng Acked-by: Morten Brørup Acked-by: Huisong Li --- drivers/net/mlx4/mlx4.c | 27 +-- drivers/net/mlx4

[PATCH v5 47/52] net/vhost: replace strerror with reentrant version

2024-11-04 Thread Dengdui Huang
The function strerror() is insecure in a multi-thread environment. This patch uses strerror_r() to replace it. Signed-off-by: Dengdui Huang Acked-by: Chengwen Feng Acked-by: Morten Brørup Acked-by: Huisong Li --- drivers/net/vhost/rte_eth_vhost.c | 14 +++--- 1 file changed, 11

[PATCH v5 18/52] common/cnxk: replace strerror with reentrant version

2024-11-04 Thread Dengdui Huang
The function strerror() is insecure in a multi-thread environment. This patch uses strerror_r() to replace it. Signed-off-by: Dengdui Huang Acked-by: Chengwen Feng Acked-by: Morten Brørup Acked-by: Huisong Li --- drivers/common/cnxk/roc_dev.c | 12 ++-- drivers/common/cnxk

[PATCH v5 43/52] net/qede: replace strerror with reentrant version

2024-11-04 Thread Dengdui Huang
The function strerror() is insecure in a multi-thread environment. This patch uses strerror_r() to replace it. Signed-off-by: Dengdui Huang Acked-by: Chengwen Feng Acked-by: Morten Brørup Acked-by: Huisong Li --- drivers/net/qede/qede_regs.c | 9 +++-- 1 file changed, 7 insertions(+), 2

[PATCH v5 42/52] net/mlx5: use rte strerror

2024-11-04 Thread Dengdui Huang
The rte_errno may be an RTE-specific error code, use rte_strerror() instead of strerror(). Signed-off-by: Dengdui Huang Acked-by: Chengwen Feng Acked-by: Morten Brørup Acked-by: Huisong Li --- drivers/net/mlx5/hws/mlx5dr_matcher.c | 2 +- drivers/net/mlx5/linux/mlx5_ethdev_os.c | 22

[PATCH v5 50/52] vdpa/ifc: replace strerror with reentrant version

2024-11-04 Thread Dengdui Huang
The function strerror() is insecure in a multi-thread environment. This patch uses strerror_r() to replace it. Signed-off-by: Dengdui Huang Acked-by: Chengwen Feng Acked-by: Morten Brørup Acked-by: Huisong Li --- drivers/vdpa/ifc/ifcvf_vdpa.c | 57 ++- 1 file

[PATCH v5 52/52] vdpa/sfc: replace strerror with reentrant version

2024-11-04 Thread Dengdui Huang
The function strerror() is insecure in a multi-thread environment. This patch uses strerror_r() to replace it. Signed-off-by: Dengdui Huang Acked-by: Chengwen Feng Acked-by: Morten Brørup Acked-by: Huisong Li --- drivers/vdpa/sfc/sfc_vdpa_ops.c | 15 --- 1 file changed, 12

[PATCH v5 28/52] net/cnxk: replace strerror with reentrant version

2024-11-04 Thread Dengdui Huang
The function strerror() is insecure in a multi-thread environment. This patch uses strerror_r() to replace it. Signed-off-by: Dengdui Huang Acked-by: Chengwen Feng Acked-by: Morten Brørup Acked-by: Huisong Li --- drivers/net/cnxk/cnxk_rep_msg.c | 9 +++-- 1 file changed, 7 insertions

[PATCH v5 49/52] raw/ifpga: replace strerror with reentrant version

2024-11-04 Thread Dengdui Huang
The function strerror() is insecure in a multi-thread environment. This patch uses strerror_r() to replace it. Signed-off-by: Dengdui Huang Acked-by: Chengwen Feng Acked-by: Morten Brørup Acked-by: Huisong Li --- drivers/raw/ifpga/afu_pmd_n3000.c | 10 -- drivers/raw/ifpga/base

  1   2   3   4   >