Re: [PATCH v3 3/3] ethdev: Reject conflicting TX offloads configuration

2025-08-04 Thread fengchengwen
On 8/4/2025 3:42 AM, Morten Brørup wrote: > When an ethdev port is configured for fast mbuf release, the driver can > use a TX burst function relying on the fast mbuf release preconditions. > Thus, also configuring this port or a queue on the port for transmitting > segmented packets is prohibited.

Re: [PATCH v3 1/3] testpmd: Do not enable mbuf fast release TX offload by default

2025-08-04 Thread fengchengwen
On 8/4/2025 3:42 AM, Morten Brørup wrote: > Enabling some offload by default may conflict with a manually configured > offload. > Specifically, the mbuf fast release TX offload, which conflicts with multi > segment packet TX offload, was enabled by default. > Therefore, mbuf fast release TX offload

Re: [PATCH v7] app/testpmd: monitor state of primary process when using secondary

2025-08-04 Thread fengchengwen
Acked-by: Chengwen Feng On 8/4/2025 7:33 PM, Khadem Ullah wrote: > In secondary processes, accessing device after primary has exited > will cause crash. > > This patch adds a mechanism in testpmd to monitor the primary process > from the secondary process. > When primary process exits it forces

Re: [EXTERNAL] [PATCH] doc: announce DMA configuration structure changes

2025-07-25 Thread fengchengwen
; configuration. >>> >>> Acked-by: Amit Prakash Shukla >> >> There is only 1 ack. >> Per our policy, it will miss the release 25.07. >> >> You can probably do this change anyway, >> and keep ABI compatibility by versioning the function.

Re: [PATCH] net: support VLAN stacking packet type parsing

2025-07-17 Thread fengchengwen
On 2025/7/4 18:18, Morten Brørup wrote: >> From: Dengdui Huang [mailto:huangdeng...@huawei.com] >> Sent: Thursday, 3 July 2025 11.30 >> >> 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 p

Re: [EXTERNAL] Re: [PATCH v0 1/1] doc: announce inter-device DMA capability support in dmadev

2025-07-16 Thread fengchengwen
e the appropriate IOMMU stream IDs >> when initiating the DMA transfers. For example, in the use case shown in the >> diagram, dmadev-1 and dmadev-2 would join an access group managed by >> the kernel DMA controller driver. This controller driver will configure the >> acce

Re: [EXTERNAL] Re: [PATCH v0 1/1] doc: announce inter-device DMA capability support in dmadev

2025-07-15 Thread fengchengwen
cess group or to query the access group details. > Additionally, a secure token mechanism (similar to vfio-pci token) can be > implemented to validate any dmadev attempting to join the access group. > > Regards. > > From: fengchengwen > Sent: Tuesday, July 15, 2025 6:29

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

2025-07-14 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/7/8 20:51, Dengdui Huang wrote: > 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 r

Re: [PATCH v0 1/1] doc: announce inter-device DMA capability support in dmadev

2025-07-14 Thread fengchengwen
Hi Vamsi, >From the commit log, I guess this commit mainly want to meet following case: --- | Container | | VirtMachine | | | | | | dmadev-1 | | dmadev2|

Re: [PATCH v3] test/argparse: change initialization to workaround LTO

2025-07-06 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/7/1 23:41, Stephen Hemminger wrote: > When compiled with Link Time Optimization, the existing code > generated an error, because the compiler was unable to intuit > that there was space in the flexible array. > > In function ‘test_argparse_copy’, > inlined fro

Re: [PATCH] test/argparse: fix out of bound memcpy

2025-07-06 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/6/28 0:22, Stephen Hemminger wrote: > The rte_argparse API use variable length arrays for the args. > But the test was only putting space on stack for the argparse > part, not the args. This can lead to out of bounds writes. > > The bug only gets detected if DPDK

Re: [PATCH v2] examples/l3fwd: adjust Tx burst size based on Rx burst

2025-06-10 Thread fengchengwen
On 2025/6/10 14:42, huangdengdui wrote: > > On 2025/6/9 23:21, Stephen Hemminger wrote: >> On Mon, 9 Jun 2025 09:58:27 + >> Sivaprasad Tummala wrote: >> >>> Previously, the TX burst size was fixed at 256, leading to performance >>> degradation in certain scenarios. >>> >>> This patch introduc

Re: [PATCH v4 2/2] test/dma: add functions to verify zero and one fill

2025-06-09 Thread fengchengwen
Hi Vidya, How about add a wrap function and keep this function (could modify it's name). static int test_enqueue_fill() { uint64_t pattern[3] = {0x0, 0xfedcba9876543210, 0x}; int i; for (i = 0; i < RTE_DIM(pattern); i++) { ret = test_enqueue

Re: [PATCH v4 1/2] test/dma: update the sg test to verify wrap around case

2025-06-09 Thread fengchengwen
Hi Vidya, On 2025/6/9 11:03, Vidya Sagar Velumuri wrote: > Run the sg test in a loop to verify wrap around case. > Total number commands submitted to be more than the number descriptors > allocated to verify the scenario. > > Signed-off-by: Vidya Sagar Velumuri > Acked-by: Amit Prakash Shukla >

Re: [PATCH v2 0/3] argparse additions and rework

2025-06-03 Thread fengchengwen
Thanks for this patchset, Bruce. Series-acked-by: Chengwen Feng On 2025/6/3 23:32, Bruce Richardson wrote: > This patchset is based off the work to adjust how we do argument parsing > inside EAL. To enable argparse to be effectively used for EAL, we have > new features and some changes in the fir

Re: [PATCH 3/3] argparse: use enums to remove max-value defines in lists

2025-06-03 Thread fengchengwen
It looks more clear and user-friendly for splitting the flag. Acked-by: Chengwen Feng On 2025/5/27 17:21, Bruce Richardson wrote: > The use of lists of #defines with _MAX entries at the end causes issues > for ABI compatibility as those MAX values often leak through to > applications and can caus

Re: [PATCH 1/3] argparse: add support for string and boolean args

2025-06-03 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/5/27 17:21, Bruce Richardson wrote: > Sometimes we don't want to parse the string at all, when doing arg > parsing, and just save it off for later. Add support for that. > > Also, rather than assuming boolean values have to be the same size as > uint8 (or some oth

Re: [PATCH 2/3] argparse: make argparse EAL-args compatible

2025-06-03 Thread fengchengwen
On 2025/5/27 17:21, Bruce Richardson wrote: > The argparse library was missing two key features which made it > unsuitable for use by EAL or any program wanting similar behaviour. > > 1. It didn't stop parsing arguments when it hit a "--" character > 2. It never returned the number of arguments pa

Re: add one example of DPI ?

2025-04-28 Thread fengchengwen
On 2025/4/28 23:49, Stephen Hemminger wrote: > On Mon, 28 Apr 2025 16:20:22 +0800 > fengchengwen wrote: > >> Hi all, >> >> Currently, we supported several DPI application scenarios performance tuning, >> in these scenarios, the DPDK library ethdev, ring

add one example of DPI ?

2025-04-28 Thread fengchengwen
Hi all, Currently, we supported several DPI application scenarios performance tuning, in these scenarios, the DPDK library ethdev, ring, mbuf and hash APIs are used. One of the scenarios is: - |

Re: [25.11 PATCH 1/3] dmadev: add enqueue dequeue operations

2025-04-24 Thread fengchengwen
Hi Pavan, On 2025/4/16 18:09, pbhagavat...@marvell.com wrote: > From: Pavan Nikhilesh > > Add enqueue/dequeue operations that use struct rte_dma_op > to communicate with the dma device. > These operations need to be enabled at dma device configuration > time by setting the flag rte_dma_conf::ena

Re: [PATCH] maintainers: update for hns3

2025-04-08 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/4/3 18:01, lihuisong (C) wrote: > > 在 2025/4/2 16:47, Jie Hai 写道: >> I am moving on to other things and dengdui is going to >> take over the role of hns3 maintainer. Update the >> MAINTAINERS accordingly. >> >> Signed-off-by: Jie Hai > Thanks for your contributio

Re: [PATCH] doc: fix year of final LTS release

2025-03-10 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/3/10 18:08, Kevin Traynor wrote: > LTS length was updated to 3 years, but a sentence saying > when the final release would be was not updated. > > Fixes: 3c60ea7b289a ("doc: update LTS maintenance to 3 years") > Cc: sta...@dpdk.org > > Signed-off-by: Kevin Trayno

Re: [PATCH] dma\ae4dma: added AMD user space DMA driver

2025-03-09 Thread fengchengwen
Hi, This commit modify the test-dma-perf and rte_mempool.h, but I can't get useful info from the commit log. So I recommend you split it to multiple commits, each commit implements a small function, and well doc in commit log, this will help reviewer better understand. Thanks On 2025/3/9 16:4

Re: [PATCH] ethdev: fix get_reg_info

2025-03-07 Thread fengchengwen
On 2025/2/18 19:58, Thierry Herbelot wrote: > 'width' and 'offset' are input parameters when dumping the register > info of an Ethernet device. They should be copied in the new request > before calling the device callback function. > > Fixes: 083db2ed9e9 ('ethdev: add report of register names and

Re: [PATCH] ethdev: fix get_reg_info

2025-03-07 Thread fengchengwen
On 2025/2/20 2:45, Stephen Hemminger wrote: > On Tue, 18 Feb 2025 12:58:28 +0100 > Thierry Herbelot wrote: > >> 'width' and 'offset' are input parameters when dumping the register >> info of an Ethernet device. They should be copied in the new request >> before calling the device callback functio

Re: [PATCH] dmadev: enable lib to be compiled with MSVC

2025-03-03 Thread fengchengwen
Acked-by: Chengwen Feng Thanks On 2025/3/4 9:55, Andre Muezerie wrote: > With the outstanding issues preventing dmadev from being compiled > with MSVC being fixed, the lib can be enabled to be compiled with MSVC. > > Signed-off-by: Andre Muezerie > --- > lib/dmadev/meson.build | 6 -- > 1

Re: [PATCH] app/test: fix DMA API tests in IOVA as PA mode

2025-02-27 Thread fengchengwen
Reviewed-by: Chengwen Feng On 2025/2/27 21:27, Bruce Richardson wrote: > When running without IOMMU for address translation, i.e. IOVAs are > physical rather than virtual addresses, we need to translate the > pointers to IOVAs for the completion API tests. > > Fixes: 9942ebb9c698 ("test/dma: add

Re: [PATCH v5 10/10] app: enable app directory to be compiled with MSVC

2025-02-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/2/22 3:52, Andre Muezerie wrote: > Enabled "app" directory to be compiled with MSVC along with all its > contents. > > Removed flag Wno-deprecated-declarations which is not needed anymore. > > Signed-off-by: Andre Muezerie > Acked-by: Bruce Richardson

Re: [PATCH v5 09/10] test: add workaround for __builtin_constant_p in test_memcpy_perf

2025-02-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/2/22 3:52, Andre Muezerie wrote: > There's no MSVC equivalent for compiler extension __builtin_constant_p, > so a workaround is needed. > > Signed-off-by: Andre Muezerie

Re: [PATCH] test/ring: fix return uninitialized variable

2025-02-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/2/19 22:23, Konstantin Ananyev wrote: > This change addresses the CID 455328: Uninitialized variables (UNINIT). > Strictly speaking right now it should never happen, as role_mask is not > zero. But that might change in future, as more test-cases will be > introduc

Re: [PATCH v2 10/14] dmadev: remove unnecessary deref of function pointers

2025-02-19 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/2/20 10:32, Stephen Hemminger wrote: > The expression *dev->dev_ops->dev_info_get and > dev->dev_ops->dev_info_get are equivalent. > > Signed-off-by: Stephen Hemminger

Re: [PATCH v3 10/10] eal: deprecate weak symbols

2025-02-18 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/2/18 23:37, David Marchand wrote: > Mark __rte_weak as deprecated. > It will avoid having to support such feature with other linkers, > plus this was never really needed. > > Signed-off-by: David Marchand

Re: [PATCH v3 01/10] bus/auxiliary: remove weak symbols

2025-02-18 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/2/18 23:37, David Marchand wrote: > Rather than use weak symbols, expose stubs symbols when needed. > > Signed-off-by: David Marchand

Re: [PATCH v3 05/10] net/hns3: remove weak symbols

2025-02-18 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/2/18 23:37, David Marchand wrote: > Rather than use weak symbols, expose stubs symbols when needed. > > Signed-off-by: David Marchand

Re: [PATCH v2] examples/l3fwd: add option to set Tx burst size

2025-02-14 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/12/4 10:06, Jie Hai wrote: > The application send packets only when the buffer is full, or the > buffer is empty and the packets to be sent extends TX_PKT_BURST. > The change of MAX_PKT_BURST make TX buffer size and TX_PKT_BURST > increase, while the default cache

Re: [PATCH v5 02/11] eal: add new secure free function

2025-02-11 Thread fengchengwen
On 2025/2/12 1:35, Stephen Hemminger wrote: > Although internally rte_free does poison the buffer in most > cases, it is useful to have function that explicitly does > this to avoid any security issues. > > Signed-off-by: Stephen Hemminger > --- > lib/eal/common/rte_malloc.c | 30 ++

Re: [PATCH v5 08/11] test: remove unneeded memset

2025-02-11 Thread fengchengwen
Signed-off-by: Chengwen Feng On 2025/2/12 1:35, Stephen Hemminger wrote: > Since tmp is not used later in the function, this memset > is unnecessary. Even though this is harmless, > it causes tools that look for security issues > around memset to flag this a bug. > > Signed-off-by: Stephen Hemmi

Re: [PATCH v5 01/11] eal: introduce new secure memory fill

2025-02-11 Thread fengchengwen
Signed-off-by: Chengwen Feng On 2025/2/12 1:35, Stephen Hemminger wrote: > When memset() is used before a release function such as free, > the compiler if allowed to optimize the memset away under > the as-if rules. This is normally ok, but in certain cases such > as passwords or security keys it

Re: [PATCH 08/10] test-pmd: declare lcore_count atomic when using C11 memory model

2025-02-11 Thread fengchengwen
Signed-off-by: Chengwen Feng On 2025/2/12 6:02, Andre Muezerie wrote: > Compiling with MSVC results in the error below: > > app/test/test_ring_perf.c(197): error C7712: address argument to atomic > operation must be a pointer to an atomic integer, > 'volatile unsigned int *' is not valid

Re: [PATCH 07/10] test-pmd: don't return value from void function

2025-02-11 Thread fengchengwen
Signed-off-by: Chengwen Feng On 2025/2/12 6:02, Andre Muezerie wrote: > Compiling with MSVC results in the warning below: > > app/test-pmd/cmdline_flow.c(13964): warning C4098: 'cmd_set_raw_parsed': > 'void' function returning a value > > Signed-off-by: Andre Muezerie

Re: [PATCH 06/10] test-pmd: avoid non-constant initializer

2025-02-11 Thread fengchengwen
Signed-off-by: Chengwen Feng On 2025/2/12 6:02, Andre Muezerie wrote: > Compiling with MSVC results in errors like the one below: > > app/test-pmd/cmdline_flow.c(8819): error C2099: initializer > is not a constant > > Signed-off-by: Andre Muezerie

Re: [PATCH 05/10] test-pmd: avoid undefined behavior

2025-02-11 Thread fengchengwen
Signed-off-by: Chengwen Feng On 2025/2/12 6:02, Andre Muezerie wrote: > Compiling with MSVC results in warnings like below: > > app/test-pmd/cmdline.c(9023): warning C5101: use of preprocessor > directive in function-like macro argument list is undefined behavior > > Signed-off-by: Andre Mu

Re: [PATCH 04/10] test-pmd: do explicit 64-bit shift to avoid implicit conversion

2025-02-11 Thread fengchengwen
Signed-off-by: Chengwen Feng On 2025/2/12 6:02, Andre Muezerie wrote: > Compiling with MSVC results in warnings like the one below: > > app/test-pmd/util.c(201): warning C4334: '<<': result of 32-bit shift > implicitly converted to 64 bits (was 64-bit shift intended?) > > Signed-off-by: And

Re: [PATCH 03/10] test-pmd: fix printf format string mismatch

2025-02-11 Thread fengchengwen
Signed-off-by: Chengwen Feng On 2025/2/12 6:01, Andre Muezerie wrote: > Compiling with MSVC results in warnings like the one below: > > app/test-pmd/csumonly.c(1085): warning C4477: 'printf' : format string > '%d' requires an argument of type 'int', > but variadic argument 1 has type 'ui

Re: [PATCH 02/10] test_alarm: avoid warning about different qualifiers

2025-02-11 Thread fengchengwen
Signed-off-by: Chengwen Feng On 2025/2/12 6:01, Andre Muezerie wrote: > Compiling with MSVC results in the warning below: > > app/test/test_alarm.c(54): warning C4090: 'function': > different '_Atomic' qualifiers > > The fix is to use a macro to explicitly drop the qualifier. > > Signed-of

Re: [PATCH 01/10] eal: add workaround for __builtin_constant_p

2025-02-11 Thread fengchengwen
Signed-off-by: Chengwen Feng On 2025/2/12 6:01, Andre Muezerie wrote: > There's no MSVC equivalent for compiler extension __builtin_constant_p. > EAL already had __rte_constant which was used as a first attempt to > workaround __builtin_constant_p when using MSVC. However, there are > pieces of c

Re: [PATCH v3 0/5] Defer lcore variables allocation

2025-02-11 Thread fengchengwen
Series-acked-by: Chengwen Feng On 2025/2/11 5:31, David Marchand wrote: > As I had reported in 24.11-rc2, the lcore variables allocation have a > noticeable impact on applications consuming DPDK, even when such > applications does not use DPDK, or use features associated to > some lcore variables

Re: [PATCH v4] test: improve resiliency of malloc autotest

2025-02-07 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/2/7 22:32, Bruce Richardson wrote: > The test case "test_multi_alloc_statistics" was brittle in that it did > some allocations and frees and then checked statistics without > considering the initial state of the malloc heaps. This meant that, > depending on what al

Re: [PATCH v3] test: improve resiliency of malloc autotest

2025-02-06 Thread fengchengwen
On 2025/2/6 19:40, Bruce Richardson wrote: > On Fri, Jan 24, 2025 at 03:18:11PM +0800, fengchengwen wrote: >> The new impl don't support re-test, how about add a wrap: >> 1. rename test_multi_alloc_statistics with do_test_multi_alloc_statistics, >> and make it tak

Re: [PATCH v4] bus: fix inconsistent representation of PCI numbers

2025-02-04 Thread fengchengwen
On 2025/1/30 2:06, Bruce Richardson wrote: > On Wed, Jan 29, 2025 at 09:17:38AM -0800, Stephen Hemminger wrote: >> On Wed, 29 Jan 2025 10:54:16 +0200 >> Shani Peretz wrote: >> >>> DPDK provides two formats for specifying PCI device numbers: >>> a full version (":08:00.0") and a short version (

Re: [PATCH v3 0/2] ethdev: clarify something about new event

2025-01-23 Thread fengchengwen
Series-acked-by: Chengwen Feng On 2025/1/17 17:12, Huisong Li wrote: > I've had some issues when I add the verification of the port id in the > event callback, which are discussed in another patch series[1]. So this > series clarify something about RTE_ETH_EVENT_NEW based on the previous > discu

Re: [PATCH v3] test: improve resiliency of malloc autotest

2025-01-23 Thread fengchengwen
The new impl don't support re-test, how about add a wrap: 1. rename test_multi_alloc_statistics with do_test_multi_alloc_statistics, and make it take socket as parameter 2. create a new function test_multi_alloc_statistics { // prepare a new malloc heap ret = do_test_multi_alloc_statistics

Re: [PATCH v2 1/2] mempool: fix rte_errno in rte_mempool_create_empty

2025-01-23 Thread fengchengwen
Acked-by: Chengwen Feng On 2025/1/20 20:21, Ariel Otilibili wrote: > When returning from rte_mempool_set_ops_byname(), rte_errno is not set > for error exits. > > The API requires rte_errno to be set in that case. > > Bugzilla ID: 1559 > Fixes: c2c6b2f41305 ("mempool: fix default ops for an emp

Re: [PATCH v3] mbuf: add fast free bulk and raw alloc bulk functions

2025-01-23 Thread fengchengwen
LGTM Acked-by: Chengwen Feng On 2025/1/21 21:40, Morten Brørup wrote: > When putting an mbuf back into its mempool, there are certain requirements > to the mbuf. Specifically, some of its fields must be initialized. > > These requirements are in fact invariants about free mbufs, held in > mempoo

Re: [EXTERNAL] Re: [PATCH 1/2] lib/dmadev: eliminate undefined behavior

2024-12-09 Thread fengchengwen
On 2024/12/10 7:21, Jerin Jacob wrote: > > >> -Original Message- >> From: Bruce Richardson >> Sent: Monday, December 9, 2024 4:58 AM >> To: Andre Muezerie ; Jerin Jacob >> >> Cc: Chengwen Feng ; Kevin Laatz >> ; dev@dpdk.org >> Subject: [EXTERNAL] Re: [PATCH 1/2] lib/dmadev: eliminate u

Re: [PATCH 0/2] enable dmadev lib to be compiled with MSVC

2024-12-08 Thread fengchengwen
Series-acked-by: Chengwen Feng Thanks On 2024/12/7 3:27, Andre Muezerie wrote: > The first patch eliminates undefined behavior in the dmadev lib: > > lib\dmadev\rte_dmadev_trace_fp.h(36): > warning C5101: use of preprocessor directive in > function-like macro argument list is undefined

Re: [PATCH v12 04/21] ethdev: remove use of VLAs for Windows built code

2024-11-22 Thread fengchengwen
On 2024/11/22 18:08, Konstantin Ananyev wrote: > > >> -Original Message----- >> From: Fengchengwen >> Sent: Friday, November 22, 2024 1:33 AM >> To: Andre Muezerie ; dev@dpdk.org >> Cc: Konstantin Ananyev >> Subject: Re: [PATCH v12 04/21] et

Re: [PATCH v4 8/9] app/test-pmd: remove redundant condition

2024-11-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/11/22 2:23, Stephen Hemminger wrote: > The loop over policy actions will always exit when it sees > the flow end action, so the next check is redundant. > > Link: https://pvs-studio.com/en/blog/posts/cpp/1179/ > > Fixes: f29fa2c59b85 ("app/testpmd: support policy

Re: [PATCH v12 06/21] hash/thash: remove use of VLAs for Windows built

2024-11-21 Thread fengchengwen
On 2024/11/22 5:41, Andre Muezerie wrote: > From: Konstantin Ananyev > > 1) ./lib/hash/rte_thash.c:774:9 > : warning: ISO C90 forbids variable length array ‘tmp_tuple’ > > The tuple can exceed sizeof(union rte_thash_tuple), for example if any > tunneling header is used in the RSS hash calcul

Re: [PATCH v12 05/21] hash: remove use of VLAs for Windows built code

2024-11-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/11/22 5:41, Andre Muezerie wrote: > From: Konstantin Ananyev > > 1) ./lib/hash/rte_cuckoo_hash.c:2362:9 > : warning: ISO C90 forbids variable length array ‘positions’ > 2) ../lib/hash/rte_cuckoo_hash.c:2478:9 > : warning: ISO C90 forbids variable length a

Re: [PATCH v12 04/21] ethdev: remove use of VLAs for Windows built code

2024-11-21 Thread fengchengwen
On 2024/11/22 5:41, Andre Muezerie wrote: > From: Konstantin Ananyev > > 1) ./lib/ethdev/rte_ethdev.c:3244:16 > : warning: ISO C90 forbids variable length array ‘xstats_names’ > 2) ./lib/ethdev/rte_ethdev.c:3345:17 > : warning: ISO C90 forbids variable length array ‘ids_copy’ > 3) ./lib/e

Re: [PATCH v12 13/21] test: remove use of VLAs for Windows built code

2024-11-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/11/22 5:41, Andre Muezerie wrote: > From: Tyler Retzlaff > > MSVC does not support VLAs, replace VLAs with standard C arrays > or alloca(). alloca() is available for all toolchain/platform > combinations officially supported by DPDK. > > Signed-off-by: Tyler Ret

Re: [PATCH v12 18/21] build: enable vla warnings on Windows built code

2024-11-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/11/22 5:41, Andre Muezerie wrote: > From: Tyler Retzlaff > > MSVC does not support optional C11 VLAs. When building for Windows > enable -Wvla so that mingw and clang also fail if a VLA is used. > > Signed-off-by: Tyler Retzlaff > Acked-by: Bruce Richardson >

Re: [PATCH v12 20/21] app/testpmd: remove use of VLAs for Windows built code in shared_rxq_fwd

2024-11-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/11/22 5:41, Andre Muezerie wrote: > MSVC does not support VLAs, replace VLAs with standard C arrays > or alloca(). alloca() is available for all toolchain/platform > combinations officially supported by DPDK. > > Signed-off-by: Andre Muezerie > --- > app/test-pm

Re: [PATCH v4 1/9] app/test: do not duplicate loop variable

2024-11-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/11/22 2:23, Stephen Hemminger wrote: > Do not use same variable for outer and inner loop in bonding test. > Since the loop is just freeing the resulting burst use bulk free. > > Link: https://pvs-studio.com/en/blog/posts/cpp/1179/ > > Fixes: 92073ef961ee ("bond:

Re: [PATCH v4 2/9] app/test: fix typo in address compare

2024-11-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/11/22 2:23, Stephen Hemminger wrote: > The first argument of 'memcmp' function was equal to the second argument. > Therefore ASSERT would always be true. > > Link: https://pvs-studio.com/en/blog/posts/cpp/1179/ > > Fixes: 92073ef961ee ("bond: unit tests") > Cc: d

Re: [PATCH v4 3/9] app/test: fix paren typo

2024-11-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/11/22 2:23, Stephen Hemminger wrote: > The parenthesis were in the wrong place so that comparison > took precedence over assignment in handling IPv6 extension > headers. Break up the loop condition to avoid the problem. > > Link: https://pvs-studio.com/en/blog/po

Re: [PATCH v4 9/9] app/test-pmd: avoid potential outside of array reference

2024-11-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/11/22 2:23, Stephen Hemminger wrote: > The order of comparison is wrong, and potentially allows > referencing past the array. > > Link: https://pvs-studio.com/en/blog/posts/cpp/1179/ > > Fixes: 3e3edab530a1 ("ethdev: add flow quota") > Cc: getel...@nvidia.com > C

Re: [PATCH v2] doc: documentation update for idxd driver

2024-11-19 Thread fengchengwen
On 2024/11/20 1:42, Thomas Monjalon wrote: > 08/10/2024 08:52, Shaiq Wani: >> Added a note to avoid usage errors by end user. >> >> Signed-off-by: Shaiq Wani >> >> v2 - addressed review comments. >> --- >> --- a/app/test-dma-perf/config.ini >> +++ b/app/test-dma-perf/config.ini >> @@ -61,6 +61,9 @

Re: [PATCH v3 10/10] app/test-dma-perf: fix parsing of DMA address

2024-11-17 Thread fengchengwen
On 2024/11/16 4:06, Stephen Hemminger wrote: > There was useless loop when looking at the DMA address. > It looks like it was meant to skip whitespace before > calling strtok. > > Good time to replace strtok with strtok_r as well. Please delete this line, with this fixed: Acked-by: Chengwen Feng

Re: [RFC 09/10] app/test-dma-perf: fix parsing of dma address

2024-11-14 Thread fengchengwen
On 2024/11/14 8:12, Stephen Hemminger wrote: > There was useless loop when looking at the DMA address. > It looks like it was meant to skip whitespace before > calling strtok. > > Good time to replace strtok with strtok_r as well. Incomplete modification for strtok, I suggest the strtok adopt Hai

Re: [PATCH v4 06/12] bus/uacce: remove memset before free

2024-11-14 Thread fengchengwen
There is no sensitive information in dev, so Acked-by: Chengwen Feng On 2024/11/15 2:43, Stephen Hemminger wrote: > Doing memset before free maybe removed by compiler, and > is flagged by security scanning tools as potential problem. > In this case the memset is unnecessary. > > Signed-off-by: S

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

2024-11-14 Thread fengchengwen
Series-acked-by: Chengwen Feng On 2024/11/14 19:39, Dengdui Huang wrote: > Whether strerror() needs to be replaced needs further discussion, > but rte_error should not be used by strerror() because rte_errno > may be an RTE-specific error code. > > This patchset use rte_strerror() instead of st

Re: [RFC 3/5] bus/uacce: remove memset before free

2024-11-13 Thread fengchengwen
On 2024/11/14 2:56, Stephen Hemminger wrote: > Doing memset before free maybe removed by compiler, and > is flagged by security scanning tools as potential problem. > In this case the memset is unnecessary. > > Signed-off-by: Stephen Hemminger > --- > drivers/bus/uacce/uacce.c | 1 - > 1 file ch

Re: [PATCH] argparse: enable code to be compiled with MSVC compiler

2024-11-12 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/11/13 6:48, Andre Muezerie wrote: > The issues that were preventing argparser from getting compiled with > MSVC were fixed, so now it should not be excluded from the > compilation anymore. > > Signed-off-by: Andre Muezerie > --- > lib/argparse/meson.build | 6 --

Re: [PATCH v3] eal/unix: optimize thread creation with glibc

2024-11-03 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/11/3 19:25, David Marchand wrote: > Setting the cpu affinity of the child thread from the parent thread is > racy when using pthread_setaffinity_np, as the child thread may start > running and initialize before affinity is set. > > On the other hand, setting the c

Re: [PATCH 1/2] config/arm: strict use of -mcpu for supported CPUs

2024-10-28 Thread fengchengwen
On 2024/10/29 7:31, Wathsala Vithanage wrote: > Arm recommends using -mcpu over -march and march-extensions when the > compiler supports the target CPU (neoverse-n1 etc.). Arm build so far > has been an amalgam of -mcpu and -march. When march is in use, it has > been the case so far to silently fal

Re: [PATCH v4 02/13] eal: replace strtok with reentrant version

2024-10-28 Thread fengchengwen
On 2024/10/28 23:31, Stephen Hemminger wrote: > On Mon, 28 Oct 2024 21:04:08 +0800 > fengchengwen wrote: > >> On 2024/10/27 11:00, Stephen Hemminger wrote: >>> On Sat, 26 Oct 2024 18:14:40 +0800 >>> Jie Hai wrote: >>> >>>> Multiple

Re: [PATCH] config/arm: fix warning for native build with meson >= 0.55

2024-10-28 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/10/28 21:10, David Marchand wrote: > Caught in UNH logs for native compilation on ARM: > > Program /./dpdk/config/arm/armv8_machine.py found: YES > (/./dpdk/config/arm/armv8_machine.py) > WARNING: Project targeting '>= 0.57' but tried to use feature

Re: [PATCH v4 02/13] eal: replace strtok with reentrant version

2024-10-28 Thread fengchengwen
On 2024/10/27 11:00, Stephen Hemminger wrote: > On Sat, 26 Oct 2024 18:14:40 +0800 > Jie Hai wrote: > >> Multiple threads calling the same function may cause condition >> race issues, which often leads to abnormal behavior and can cause >> more serious vulnerabilities such as abnormal termination

Re: [PATCH v2 0/6] Reduce scope address-of-packed-member warning

2024-10-28 Thread fengchengwen
LGTM Series-acked-by: Chengwen Feng On 2024/10/26 0:50, Bruce Richardson wrote: > The warning for address-of-packed-member was being disabled globally in > DPDK. While for drivers which need to access hardware-defined > data-structures the use of packed may make sense, for normal libs and > appl

Re: [PATCH] dumpcap: check return value from adding interface

2024-10-27 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/10/28 2:28, Stephen Hemminger wrote: > The rte_pcapng_add_interface could fail. > For example: running out of space for the file. > > Covertity issue: 446742 > Signed-off-by: Stephen Hemminger

Re: [PATCH v13 2/3] examples/l3fwd-power: fix data overflow when parse command line

2024-10-25 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/10/25 17:18, Huisong Li wrote: > Many variables are 'uint32_t', like, 'pause_duration', 'scale_freq_min' > and so on. They use parse_int() to parse it from command line. > But overflow problem occurs when this function return. > > Fixes: 59f2853c4cae ("examples/l3

Re: [PATCH v2 1/2] net/hns3: fix variable type

2024-10-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/10/22 12:01, Jie Hai wrote: > The patch fixes variable type in case of data trunction. > > Fixes: dd4b8bba785f ("net/hns3: support reporting names of registers") > Cc: sta...@dpdk.org > > Signed-off-by: Jie Hai > --- > drivers/net/hns3/hns3_regs.c | 4 ++-- > 1

Re: Use of strtok() in dpdk code

2024-10-21 Thread fengchengwen
On 2024/10/22 9:08, Stephen Hemminger wrote: > On Mon, 21 Oct 2024 21:30:02 +0300 > Isaac Boukris wrote: > >> Hello, >> >> I was debugging a crash resulting from strtok() returning NULL >> unexpectedly (string still had tokens and delimiters), and the only >> explanation I could come up with was

Re: [PATCH v2 2/2] net/hns3: fix pointer offset

2024-10-21 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/10/22 12:01, Jie Hai wrote: > If the register values of multiple modules are obtained at a time, > the register values are incorrect because the data field to be filled > pointing to a wrong address. Update the pointer offset of data to > get the correct address. >

Re: [PATCH v4 0/6] refine argparse library

2024-10-21 Thread fengchengwen
On 2024/10/18 22:46, Thomas Monjalon wrote: > 18/10/2024 03:09, fengchengwen: >> Hi Thomas and David, >> >> This patchset was already acked by Stephen. >> It missed in DPDK 24.07, hope merge in 24.11. >> >> Thanks >> >> On 2024/10/1

Re: [PATCH 4/4] net/hns3: support outer VLAN flow match

2024-10-20 Thread fengchengwen
On 2024/10/19 0:41, Stephen Hemminger wrote: > On Fri, 18 Oct 2024 14:19:41 +0800 > Jie Hai wrote: > >> @@ -306,11 +324,16 @@ hns3_parse_devargs(struct rte_eth_dev *dev) >> &hns3_parse_dev_caps_mask, &dev_caps_mask); >> (void)rte_kvargs_process(kvlist, HNS3_DEVARG_MBX

Re: [PATCH v4 0/6] refine argparse library

2024-10-17 Thread fengchengwen
Hi Thomas and David, This patchset was already acked by Stephen. It missed in DPDK 24.07, hope merge in 24.11. Thanks On 2024/10/10 9:35, fengchengwen wrote: > Hi Thomas and David, > > Kindly ping for merge. > > On 2024/10/10 3:33, Stephen Hemminger wrote: >> On Mon,

Re: [PATCH v3 2/2] examples/l3fwd: add option to set mbuf cache size

2024-10-17 Thread fengchengwen
There's a little tip that can be modified, with that modified: Acked-by: Chengwen Feng On 2024/10/17 17:58, Jie Hai wrote: > The mempool cache size of mbuf is set to > RTE_MEMPOOL_CACHE_MAX_SIZE as default. This patch allows > users to configure the cache size by "--mbcache", and limits > the par

Re: [PATCH] net: improve vlan header type alignment

2024-10-13 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/10/13 16:35, Morten Brørup wrote: > Ethernet packets can be VLAN tagged, i.e. an Ethernet header can have a > VLAN tag (a.k.a. VLAN header) embedded. > Since the Ethernet header is 2 byte aligned, and the VLAN tag is directly > related to the Ethernet header, the V

Re: [PATCH 1/4] ethdev: verify queue ID when Tx done cleanup

2024-10-12 Thread fengchengwen
On 2024/10/12 10:27, Ferruh Yigit wrote: > On 9/5/2024 8:33 AM, Andrew Rybchenko wrote: >> On 9/5/24 09:46, Jie Hai wrote: >>> From: Chengwen Feng >>> >>> Verify queue_id for rte_eth_tx_done_cleanup API. >> >> If I'm not mistaken the function is considered data path API (fast). >> If so, it should

Re: [PATCH] examples/l3fwd: add option to set RX burst size

2024-10-12 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/10/12 16:40, Jie Hai wrote: > Now the Rx burst size is fixed to MAX_PKT_BURST (32). This > parameter needs to be modified in some performance optimization > scenarios. So an option '--burst' is added to set the burst size > explicitly. The default value is DEFAULT_

Re: [PATCH v6 0/4] fix segment fault when parse args

2024-10-11 Thread fengchengwen
On 2024/10/11 22:13, David Marchand wrote: > On Wed, Oct 9, 2024 at 6:50 AM Chengwen Feng wrote: >> >> The rte_kvargs_process() was used to parse key-value (e.g. socket_id=0), >> it also supports to parse only-key (e.g. socket_id). But many drivers's >> callback can only handle key-value, it will

Re: [PATCH v5 1/1] dmadev: support strict priority configuration

2024-10-11 Thread fengchengwen
Acked-by: Chengwen Feng On 2024/10/11 17:13, Vamsi Krishna wrote: > From: Vamsi Attunuru > > Some DMA controllers offer the ability to configure priority > level for the DMA channels, allowing for the prioritization > of DMA command execution based on channel importance. > > This patch support

Re: [PATCH 1/7] app/test: introduce UT suite framework for kvargs

2024-10-10 Thread fengchengwen
On 2024/10/11 10:08, Stephen Hemminger wrote: > On Fri, 3 Nov 2023 09:53:19 + > Chengwen Feng wrote: > >> Introduce unit test suite framework for test_kvargs.c. >> >> Signed-off-by: Chengwen Feng >> --- >> app/test/test_kvargs.c | 20 +--- >> 1 file changed, 13 insertions(+)

Re: [PATCH v4 0/6] refine argparse library

2024-10-09 Thread fengchengwen
Hi Thomas and David, Kindly ping for merge. On 2024/10/10 3:33, Stephen Hemminger wrote: > On Mon, 18 Mar 2024 11:18:32 + > Chengwen Feng wrote: > >> I found a couple of issues when I revisited the argparse_autotest >> output, so got this patchset. >> >> Chengwen Feng (6): >> argparse: re

Re: [PATCH v2] net/mvneta: fix possible out-of-bounds write

2024-10-09 Thread fengchengwen
On 2024/10/10 2:00, Stephen Hemminger wrote: > On Wed, 9 Oct 2024 06:08:45 + > Chengwen Feng wrote: > >> The mvneta_ifnames_get() function will save 'iface' value to ifnames, >> it will out-of-bounds write if passed many iface pairs (e.g. >> 'iface=xxx,iface=xxx,...'). >> >> Fixes: 4ccc8d770d

Re: [PATCH v2 1/3] ethdev: add traffic manager query function

2024-10-09 Thread fengchengwen
On 2024/10/9 16:07, Bruce Richardson wrote: > On Wed, Oct 09, 2024 at 08:57:41AM +0800, fengchengwen wrote: >> On 2024/10/8 22:43, Bruce Richardson wrote: >>> Add function to allow querying a node in the scheduler tree. Returns >>> the parameters as were given to th

  1   2   3   4   5   6   7   >