[dpdk-dev] [PATCH] cryptodev: formalize key wrap method in API

2021-03-15 Thread Matan Azrad
The Key Wrap approach is used by applications in order to protect keys located in untrusted storage or transmitted over untrusted communications networks. The constructions are typically built from standard primitives such as block ciphers and cryptographic hash functions. The Key Wrap method and

Re: [dpdk-dev] [PATCH] app/testpmd: fix unchecked return value

2021-03-15 Thread Li, Xiaoyun
> -Original Message- > From: Kalesh A P > Sent: Tuesday, March 16, 2021 14:52 > To: dev@dpdk.org > Cc: Li, Xiaoyun ; Yigit, Ferruh > Subject: [dpdk-dev] [PATCH] app/testpmd: fix unchecked return value > > From: Kalesh AP > > This patch checks return value for rte_eth_dev_info_get() in

[dpdk-dev] [PATCH] app/testpmd: fix unchecked return value

2021-03-15 Thread Kalesh A P
From: Kalesh AP This patch checks return value for rte_eth_dev_info_get() in show_macs(). Coverity issue: 353629 Fixes: e1d44d0ad623 ("app/testpmd: show MAC addresses added to a port") Cc: sta...@dpdk.org Signed-off-by: Kalesh AP --- app/test-pmd/config.c | 3 ++- 1 file changed, 2 insertions

[dpdk-dev] [PATCH v3 8/8] drivers: add common driver API to get efx family

2021-03-15 Thread Andrew Rybchenko
From: Vijay Kumar Srivastava Move function to get efx family from net driver into common driver. Signed-off-by: Vijay Kumar Srivastava Signed-off-by: Andrew Rybchenko --- drivers/common/meson.build | 2 +- drivers/common/sfc_efx/meson.build | 6 +++ drivers/common/sfc_efx/sfc_efx.c

[dpdk-dev] [PATCH v3 7/8] net/sfc: skip driver probe for incompatible device class

2021-03-15 Thread Andrew Rybchenko
From: Vijay Kumar Srivastava Driver would be probed only for the net device class. Signed-off-by: Vijay Kumar Srivastava Signed-off-by: Andrew Rybchenko --- doc/guides/nics/sfc_efx.rst | 8 drivers/net/sfc/sfc.h| 1 + drivers/net/sfc/sfc_ethdev.c | 7 +++ drivers/net/sfc

[dpdk-dev] [PATCH v3 6/8] common/sfc_efx: add support to get the device class

2021-03-15 Thread Andrew Rybchenko
From: Vijay Kumar Srivastava Device class argument would be used to select compatible driver. Driver probe would be skipped for incompatible device class. Signed-off-by: Vijay Kumar Srivastava Signed-off-by: Andrew Rybchenko --- drivers/common/sfc_efx/sfc_efx.c | 49

[dpdk-dev] [PATCH v3 5/8] common/sfc_efx/base: add support to verify virtio features

2021-03-15 Thread Andrew Rybchenko
From: Vijay Kumar Srivastava Add an API to verify virtio features supported by device. Signed-off-by: Vijay Kumar Srivastava Signed-off-by: Andrew Rybchenko --- drivers/common/sfc_efx/base/efx.h | 7 drivers/common/sfc_efx/base/efx_impl.h | 2 + drivers/common/sfc_efx/base

[dpdk-dev] [PATCH v3 4/8] common/sfc_efx/base: add support to get virtio features

2021-03-15 Thread Andrew Rybchenko
From: Vijay Kumar Srivastava Add an API to get virtio features supported by device. Signed-off-by: Vijay Kumar Srivastava Signed-off-by: Andrew Rybchenko --- drivers/common/sfc_efx/base/efx.h | 14 ++ drivers/common/sfc_efx/base/efx_impl.h | 2 + drivers/common/sfc_efx/base/

[dpdk-dev] [PATCH v3 3/8] common/sfc_efx/base: add virtio build dependency

2021-03-15 Thread Andrew Rybchenko
From: Vijay Kumar Srivastava Add EFSYS_HAS_UINT64 build dependency on EFSYS_OPT_VIRTIO. virtio features are represented as bitmask in 64-bit unsigned integer. Signed-off-by: Vijay Kumar Srivastava Signed-off-by: Andrew Rybchenko --- drivers/common/sfc_efx/base/efx_check.h | 3 +++ 1 file chan

[dpdk-dev] [PATCH v3 1/8] common/sfc_efx/base: add base virtio support for vDPA

2021-03-15 Thread Andrew Rybchenko
From: Vijay Srivastava In the vDPA mode, only data path is offloaded in the hardware and control path still goes through the hypervisor and it configures virtqueues via vDPA driver so new virtqueue APIs are required. Implement virtio init/fini and virtqueue create/destroy APIs. Signed-off-by: V

[dpdk-dev] [PATCH v3 2/8] common/sfc_efx/base: add API to get VirtQ doorbell offset

2021-03-15 Thread Andrew Rybchenko
From: Vijay Srivastava Add an API to query the virtqueue doorbell offset in the BAR for a VI. For vDPA, the virtio net driver notifies the device directly by writing doorbell. This API would be invoked from vDPA client driver. Signed-off-by: Vijay Srivastava Signed-off-by: Andrew Rybchenko ---

[dpdk-dev] [PATCH v3 0/8] common/sfc_efx: prepare to introduce vDPA driver

2021-03-15 Thread Andrew Rybchenko
Update base driver to provide functionality required by vDPA driver. Factor out helper functions to be shared by net and vDPA drivers. v3: - one more attempt to fix windows build breakage v2: - fix windows build breakage - do not build common/sfc_efx in the case of windows - remove undefin

Re: [dpdk-dev] [EXT] Re: [PATCH 7/7] eventdev: fix ABI breakage due to event vector

2021-03-15 Thread Pavan Nikhilesh Bhagavatula
>On Mon, Mar 8, 2021 at 7:44 PM Jerin Jacob >wrote: >> Summary: >> 1) Ideal way of adding this feature is to add elements in the >> existing structure as mentioned >> in ("eventdev: introduce event vector Rx capability") in this series. >> 2) Since this breaking ABI, Introducing a new structure

Re: [dpdk-dev] [PATCH] app/testpmd: fix unchecked return value

2021-03-15 Thread Li, Xiaoyun
Hi > -Original Message- > From: Kalesh A P > Sent: Tuesday, March 16, 2021 12:55 > To: dev@dpdk.org > Cc: Li, Xiaoyun ; Yigit, Ferruh > Subject: [dpdk-dev] [PATCH] app/testpmd: fix unchecked return value > > From: Kalesh AP > > CID 353629 (#1 of 1): Unchecked return value (CHECKED_RET

Re: [dpdk-dev] [PATCH 0/2] support block cipher DIGEST_ENCRYPTED mode

2021-03-15 Thread Anoob Joseph
Series Acked-by: Anoob Joseph > > This series adds support for block cipher DIGEST_ENCRYPTED mode in > OCTEON TX, OCTEON TX2 PMDs and sample unit test application. > > Tejasree Kondoj (2): > common/cpt: support DIGEST_ENCRYPTED mode > test/crypto: support block cipher DIGEST_ENCRYPTED mode

[dpdk-dev] [PATCH] net/bnxt: fix unchecked return value

2021-03-15 Thread Kalesh A P
From: Kalesh AP CID 363716 (#1 of 1): Unchecked return value (CHECKED_RETURN) check_return: Calling rte_pci_write_config without checking return value (as is done elsewhere 46 out of 49 times). Coverity issue: 363716 Fixes: be14720def9c ("net/bnxt: support FW reset") Cc: sta...@dpdk.org Signed

[dpdk-dev] [PATCH] app/testpmd: fix unchecked return value

2021-03-15 Thread Kalesh A P
From: Kalesh AP CID 353629 (#1 of 1): Unchecked return value (CHECKED_RETURN) check_return: Calling rte_eth_dev_info_get without checking return value (as is done elsewhere 110 out of 117 times). Coverity issue: 353629 Fixes: e1d44d0ad623 ("app/testpmd: show MAC addresses added to a port") Cc:

[dpdk-dev] [PATCH] app/testpmd: fix the miss configuration for NVGRE encap

2021-03-15 Thread Jiawei Wang
For NVGRE protocol, the default value of c_k_s_rsvd0_ver must be 0x2000, and protocol type must be 0x6558 in the NVGRE header. This patch updates these two configuraitons while parser the nvgre encap. Fixes: dcd962fc6b ("app/testpmd: add NVGRE encap/decap") Cc: sta...@dpdk.org Signed-off-by: Jia

Re: [dpdk-dev] Duplicating traffic with RTE Flow

2021-03-15 Thread Jiawei(Jonny) Wang
Hi Jan, > -Original Message- > From: Jan Viktorin > Sent: Monday, March 15, 2021 9:22 PM > To: Jiawei(Jonny) Wang > Cc: Slava Ovsiienko ; Asaf Penso > ; dev@dpdk.org; Ori Kam > Subject: Re: [dpdk-dev] Duplicating traffic with RTE Flow > > Hello Jiawei, > > On Fri, 12 Mar 2021 09:32:4

[dpdk-dev] [PATCH v3] eal, power: use UINT64_MAX and UINT32_MAX

2021-03-15 Thread Tyler Retzlaff
Use UINT64_MAX and UINT32_MAX instead of -1 or ~0 literal variations of different explicit widths when creating masks and sentinel values. some compilers generate a warning when applying a '-' to an unsigned literal so avoid this by initializing with unsigned preprocessor definitions where appropr

[dpdk-dev] [PATCH] eal: check vsnprintf failure and return -EINVAL

2021-03-15 Thread Tyler Retzlaff
Check for failure, while here just increment len once after checking for failure instead of duplicating len + 1 math in two different argument lists. Signed-off-by: Tyler Retzlaff --- lib/librte_eal/common/eal_common_devargs.c | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff

Re: [dpdk-dev] [PATCH v4 2/2] eal: rename key opaque pointer and functions in TLS API

2021-03-15 Thread Thomas Monjalon
10/03/2021 13:48, Tal Shnaiderman: > rename the key opaque pointer from rte_tls_key to > rte_thread_key to avoid confusion with transport layer security. > > Also rename and remove the "_tls" term from the following > functions to avoid redundancy: > > rte_thread_tls_key_create > rte_thread_tls_k

Re: [dpdk-dev] [PATCH v4 1/2] eal: error number enhancement for thread TLS API

2021-03-15 Thread Thomas Monjalon
10/03/2021 13:48, Tal Shnaiderman: > --- a/lib/librte_eal/include/rte_thread.h > +++ b/lib/librte_eal/include/rte_thread.h > @@ -59,7 +59,9 @@ void rte_thread_get_affinity(rte_cpuset_t *cpusetp); > * > * @return > * On success, zero. > - * On failure, a negative number. > + * On failure

Re: [dpdk-dev] [dpdk-stable] [PATCH] log/linux: make default output stderr

2021-03-15 Thread Thomas Monjalon
09/02/2021 16:06, Ferruh Yigit: > In Linux by default DPDK log goes to stdout, as well as syslog. > > It is possible for an application to change the library output stream > via 'rte_openlog_stream()' API, to set it to stderr, it can be used as: > rte_openlog_stream(stderr); > > But still updatin

[dpdk-dev] [PATCH v4 2/2] pipeline: add meter support to the SWX pipeline

2021-03-15 Thread Cristian Dumitrescu
Meter arrays are stateful objects that are updated by the data plane and configured & monitored by the control plane. The meters implement the RFC 2698 Two Rate Three Color Marker (trTCM) algorithm. Signed-off-by: Cristian Dumitrescu --- examples/pipeline/cli.c | 471 ++

[dpdk-dev] [PATCH v4 1/2] pipeline: add register array support to SWX pipeline

2021-03-15 Thread Cristian Dumitrescu
Register arrays are stateful objects that can be read & modified by both the data plane and the control plane, as opposed to tables, which are read-only for data plane. One key use-case is the implementation of stats counters. Signed-off-by: Cristian Dumitrescu --- examples/pipeline/cli.c

Re: [dpdk-dev] [PATCH v6] build: kni cross-compilation support

2021-03-15 Thread Thomas Monjalon
11/02/2021 13:59, Juraj Linkeš: > The kni linux module is using a custom target for building, which > doesn't take into account any cross compilation arguments. The arguments > in question are ARCH, CROSS_COMPILE (for gcc, clang) and CC, LD (for > clang). Get those from the cross file and pass them

Re: [dpdk-dev] [PATCH v2] eal: fix querying DPDK version at runtime

2021-03-15 Thread Thomas Monjalon
16/02/2021 16:13, Bruce Richardson: > For using a DPDK application, such as OVS, which is dynamically linked, the > DPDK version in use should always report the actual version, not the > version used at build time. This incorrect behaviour can be seen by > building OVS against one version of DPDK a

[dpdk-dev] [PATCH v3 2/2] pipeline: add meter support to the SWX pipeline

2021-03-15 Thread Cristian Dumitrescu
Meter arrays are stateful objects that are updated by the data plane and configured & monitored by the control plane. The meters implement the RFC 2698 Two Rate Three Color Marker (trTCM) algorithm. Signed-off-by: Cristian Dumitrescu --- examples/pipeline/cli.c | 471 ++

[dpdk-dev] [PATCH v3 1/2] pipeline: add register array support to SWX pipeline

2021-03-15 Thread Cristian Dumitrescu
Register arrays are stateful objects that can be read & modified by both the data plane and the control plane, as opposed to tables, which are read-only for data plane. One key use-case is the implementation of stats counters. Signed-off-by: Cristian Dumitrescu --- examples/pipeline/cli.c

[dpdk-dev] [PATCH] net/cxgbe: disable Rx path during port link down

2021-03-15 Thread Rahul Lakkireddy
When link goes down, disable the port's Rx path to drop the incoming traffic closer to the wire, instead of accepting them in for further Rx processing, only to eventually drop them at the port's Rxqs. This prevents unnecessary congestion in the Rx path. The port's Rx path will be re-enabled once t

[dpdk-dev] [PATCH 2/2] common/mlx5: rename driver name to include PCI notation

2021-03-15 Thread Michael Baum
From: Asaf Penso The current define for MLX5_DRIVER_NAME refers specially for the PCI driver. The define itself does not mention PCI and this is confusing. Rename from MLX5_DRIVER_NAME to MLX5_PCI_DRIVER_NAME. Signed-off-by: Asaf Penso --- drivers/common/mlx5/mlx5_common.h | 2 +- driver

[dpdk-dev] [PATCH 1/2] common/mlx5: align driver name logs across pmds

2021-03-15 Thread Michael Baum
From: Asaf Penso Some mlx5 pmds define the log prefix as "mlx5_pmd" while others as "pmd_mlx5". The patch aligns all pmds to use the "mlx5_pmd" format. Signed-off-by: Asaf Penso --- drivers/common/mlx5/mlx5_common.h | 4 drivers/common/mlx5/mlx5_common_utils.h | 2 +- drivers/net/ml

Re: [dpdk-dev] [PATCH 2/2] net/mlx5: avoid unbind step to enable switchdev mode

2021-03-15 Thread Jan Viktorin
On Mon, 15 Mar 2021 19:52:46 + Slava Ovsiienko wrote: > Hi, Jan > > > -Original Message- > > From: Jan Viktorin > > Sent: Monday, March 15, 2021 21:49 > > To: Slava Ovsiienko > > Cc: dev@dpdk.org; Asaf Penso ; Shahaf Shuler > > ; Matan Azrad > > Subject: Re: [PATCH 2/2] net/mlx5:

Re: [dpdk-dev] [PATCH 2/2] net/mlx5: avoid unbind step to enable switchdev mode

2021-03-15 Thread Slava Ovsiienko
Hi, Jan > -Original Message- > From: Jan Viktorin > Sent: Monday, March 15, 2021 21:49 > To: Slava Ovsiienko > Cc: dev@dpdk.org; Asaf Penso ; Shahaf Shuler > ; Matan Azrad > Subject: Re: [PATCH 2/2] net/mlx5: avoid unbind step to enable switchdev > mode > > On Mon, 15 Mar 2021 19:31:25

Re: [dpdk-dev] [PATCH 2/2] net/mlx5: avoid unbind step to enable switchdev mode

2021-03-15 Thread Jan Viktorin
On Mon, 15 Mar 2021 19:31:25 + Slava Ovsiienko wrote: > Hi, Jan Hello Salva, I am sorry, but I didn't get the point of your response. For me, there was 1 PF :05:00.1, SRIOV disabled. So, I followed the guide [1]. 1. Enable SRIOV via mlxconfig. Done. 2. Configure max number of VFs. Don

Re: [dpdk-dev] [PATCH] ppc64le: fix build with Clang and without glibc

2021-03-15 Thread David Christensen
On 3/11/21 8:11 AM, Piotr Kubaj wrote: There are couple of issues when building with Clang: 1. vector is a keyword and should not be used in code. I undefined it, but it would probably be better to just change the variable name. 2. vector long is deprecated by Clang and should not be used. I s

Re: [dpdk-dev] [PATCH 0/2] Mark shared pthread mutex

2021-03-15 Thread Stephen Hemminger
On Mon, 15 Mar 2021 12:27:20 -0700 Stephen Hemminger wrote: > This fixes two places where pthread_mutex was being unsafely > used between primary secondary process. > > These patches are necessary but not sufficient to address Bug 662 > > Stephen Hemminger (2): > ethdev: make flow API primary

[dpdk-dev] [PATCH v2] doc: propose correction rte_{bsf, fls} inline functions type use

2021-03-15 Thread Tyler Retzlaff
The proposal has resulted from request to review [1] the following functions where there appeared to be inconsistency in return type or parameter type selections for the following inline functions. rte_bsf32() rte_bsf32_safe() rte_bsf64() rte_bsf64_safe() rte_fls_u32() rte_fls_u64() rte_log2_u32()

Re: [dpdk-dev] [PATCH 2/2] net/mlx5: avoid unbind step to enable switchdev mode

2021-03-15 Thread Slava Ovsiienko
Hi, Jan 1. Let's suppose we have the one port NIC, PCI BDF 08:00.0, SR-IOV enabled, 0 VFs is configured, netdev name is ens1f0 (depends on distro and kernel version). 2. Then, we configure 3 VFs with SR-IOV, we get : - 08:00.0 - PF, ens1f0 - 08:00.1 - VF0, ens1f1 - 08:00.2 - VF1, ens1f2 - 08:00

[dpdk-dev] [PATCH 2/2] net/failsafe: fix primary/secondary mutex

2021-03-15 Thread Stephen Hemminger
Set mutex used in failsafe driver to protect when used by both primary and secondary process. Without this fix, the failsafe lock is not really locking when there are multiple secondary processes. Bugzilla ID: 662 Signed-off-by: Stephen Hemminger Fixes: 655fcd68c7d2 ("net/failsafe: fix hotplug ra

[dpdk-dev] [PATCH 0/2] Mark shared pthread mutex

2021-03-15 Thread Stephen Hemminger
This fixes two places where pthread_mutex was being unsafely used between primary secondary process. These patches are necessary but not sufficient to address Bug 662 Stephen Hemminger (2): ethdev: make flow API primary/secondary process safe net/failsafe: fix primary/secondary mutex driver

[dpdk-dev] [PATCH 1/2] ethdev: make flow API primary/secondary process safe

2021-03-15 Thread Stephen Hemminger
Posix mutex are not by default safe for protecting for usage from multiple processes. The flow ops mutex could be used by both primary and secondary processes. Bugzilla ID: 662 Signed-off-by: Stephen Hemminger Fixes: 80d1a9aff7f6 ("ethdev: make flow API thread safe") Cc: suanmi...@nvidia.com ---

[dpdk-dev] [Bug 662] Pthread_mutex usage is not safe between primar/secondary process

2021-03-15 Thread bugzilla
https://bugs.dpdk.org/show_bug.cgi?id=662 Bug ID: 662 Summary: Pthread_mutex usage is not safe between primar/secondary process Product: DPDK Version: 18.11 Hardware: All OS: All Status: UNCONFIR

Re: [dpdk-dev] [dpdk-stable] [PATCH v2] vhost: add header check in dequeue offload

2021-03-15 Thread Ananyev, Konstantin
> -Original Message- > From: David Marchand > Sent: Monday, March 15, 2021 4:17 PM > To: Wang, Xiao W > Cc: Xia, Chenbo ; Maxime Coquelin > ; Liu, Yong ; dev > ; Ananyev, Konstantin ; dpdk > stable > Subject: Re: [dpdk-stable] [PATCH v2] vhost: add header check in dequeue > offload

Re: [dpdk-dev] Duplicating traffic with RTE Flow

2021-03-15 Thread Jan Viktorin
OK, after firmware update, it seems that it works now. Thank you for help! Jan On Mon, 15 Mar 2021 14:22:16 +0100 Jan Viktorin wrote: > Hello Jiawei, > > On Fri, 12 Mar 2021 09:32:44 + > "Jiawei(Jonny) Wang" wrote: > > > Hi Jan, > > > > > -Original Message- > > > From: Jan Vi

Re: [dpdk-dev] [PATCH 3/3] net/i40e: fix segment fault in AVX512

2021-03-15 Thread Coyle, David
Hi Wenzhuo > -Original Message- > From: dev On Behalf Of Wenzhuo Lu > Sent: Friday, March 12, 2021 1:27 AM > To: dev@dpdk.org > Cc: Lu, Wenzhuo ; sta...@dpdk.org > Subject: [dpdk-dev] [PATCH 3/3] net/i40e: fix segment fault in AVX512 > > Fix segment fault when failing to get the memory f

Re: [dpdk-dev] [PATCH 2/3] net/ice: fix segment fault in AVX512

2021-03-15 Thread Coyle, David
Hi Wenzhuo > -Original Message- > From: dev On Behalf Of Wenzhuo Lu > Sent: Friday, March 12, 2021 1:27 AM > To: dev@dpdk.org > Cc: Lu, Wenzhuo ; sta...@dpdk.org > Subject: [dpdk-dev] [PATCH 2/3] net/ice: fix segment fault in AVX512 > > Fix segment fault when failing to get the memory fr

Re: [dpdk-dev] [PATCH 2/2] kni: fix rtnl deadlocks and race conditions v4

2021-03-15 Thread Ferruh Yigit
On 2/25/2021 2:32 PM, Elad Nachman wrote: This part of the series includes my fixes for the issues reported by Ferruh and Igor (and Igor comments for v3 of the patch) on top of part 1 of the patch series: A. KNI sync lock is being locked while rtnl is held. If two threads are calling kni_net_pro

Re: [dpdk-dev] [PATCH 1/2] kni: fix kernel deadlock when using mlx devices

2021-03-15 Thread Ferruh Yigit
On 2/25/2021 2:32 PM, Elad Nachman wrote: This first part of v4 of the patch re-introduces Stephen Hemminger's patch 64106 . This part changes the parameter kni_net_process_request() gets and introduces the initial rtnl unlocking mechanism. Signed-off-by: Elad Nachman --- v4: * for if down case

Re: [dpdk-dev] [PATCH 1/3] net/iavf: fix segment fault in AVX512

2021-03-15 Thread Coyle, David
Hi Wenzhuo > -Original Message- > From: dev On Behalf Of Wenzhuo Lu > Sent: Friday, March 12, 2021 1:27 AM > To: dev@dpdk.org > Cc: Lu, Wenzhuo ; sta...@dpdk.org > Subject: [dpdk-dev] [PATCH 1/3] net/iavf: fix segment fault in AVX512 > > Fix segment fault when failing to get the memory f

Re: [dpdk-dev] [PATCH] build: skip copying meson files for examples installation

2021-03-15 Thread Thomas Monjalon
12/03/2021 15:56, Bruce Richardson: > The meson.build files in each example directory is simply to support > building the example as part of the main SDK build, and these should not > be installed with the example's source code and makefile. The exclude of > "meson.build" only filters out the top-l

Re: [dpdk-dev] [PATCH v3 3/4] net/virtio: allocate fake mbuf in Rx queue

2021-03-15 Thread Maxime Coquelin
On 3/15/21 5:57 PM, David Marchand wrote: > On Mon, Mar 15, 2021 at 5:46 PM Maxime Coquelin > wrote: >> @@ -612,6 +622,8 @@ virtio_init_queue(struct rte_eth_dev *dev, uint16_t >> queue_idx) >> >> clean_vq: >> hw->cvq = NULL; >> + rte_free(fake_mbuf); >> +free_sw_ring: >>

Re: [dpdk-dev] [PATCH v3 07/11] eal: add log level help

2021-03-15 Thread Kinsella, Ray
On 15/03/2021 15:59, Stephen Hemminger wrote: > On Mon, 15 Mar 2021 11:52:13 +0100 > Thomas Monjalon wrote: > >> 15/03/2021 11:42, Kinsella, Ray: >>> >>> On 15/03/2021 10:31, Bruce Richardson wrote: On Mon, Mar 15, 2021 at 10:19:47AM +, Kinsella, Ray wrote: > > > On 12

Re: [dpdk-dev] [PATCH v3 0/4] net/virtio: make virtqueue struct cache-friendly

2021-03-15 Thread David Marchand
On Mon, Mar 15, 2021 at 5:46 PM Maxime Coquelin wrote: > > This series optimizes the cache usage of virtqueue struct, > by making a "fake" mbuf being dynamically allocated in Rx > virtnet struct, by removing a useless virtuque pointer > into the virtnet structs and by moving a few fields > to pack

Re: [dpdk-dev] [PATCH 2/2] kni: fix rtnl deadlocks and race conditions v4

2021-03-15 Thread Ferruh Yigit
On 3/1/2021 4:38 PM, Stephen Hemminger wrote: On Mon, 1 Mar 2021 11:10:01 +0300 Igor Ryzhov wrote: Stephen, No, I don't have a better proposal, but I think it is not correct to change the behavior of KNI (making link down without a real response). Even though we know that communicating with u

Re: [dpdk-dev] [PATCH v3 3/4] net/virtio: allocate fake mbuf in Rx queue

2021-03-15 Thread David Marchand
On Mon, Mar 15, 2021 at 5:46 PM Maxime Coquelin wrote: > @@ -612,6 +622,8 @@ virtio_init_queue(struct rte_eth_dev *dev, uint16_t > queue_idx) > > clean_vq: > hw->cvq = NULL; > + rte_free(fake_mbuf); > +free_sw_ring: > rte_free(sw_ring); > free_hdr_mz: > rte_memzone

[dpdk-dev] [PATCH v3 4/4] net/virtio: pack virtqueue struct

2021-03-15 Thread Maxime Coquelin
This patch optimizes packing of the virtqueue struct by moving fields around to fill holes. Offset field is not used and so can be removed. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- drivers/net/virtio/virtqueue.h | 18 +- 1 file changed, 9 insertions(+), 9 dele

[dpdk-dev] [PATCH v3 3/4] net/virtio: allocate fake mbuf in Rx queue

2021-03-15 Thread Maxime Coquelin
While it is worth clarifying whether the fake mbuf in virtnet_rx struct is really necessary, it is sure that it heavily impacts cache usage by being part of the struct. Indeed, it uses two cachelines, and requires alignment on a cacheline. Before this series, it means it took 120 bytes in virtnet_

[dpdk-dev] [PATCH v3 2/4] net/virtio: improve queue init error path

2021-03-15 Thread Maxime Coquelin
This patch improves the error path of virtio_init_queue(), by cleaning in reversing order all resources that have been allocated. Suggested-by: Chenbo Xia Signed-off-by: Maxime Coquelin --- drivers/net/virtio/virtio_ethdev.c | 15 ++- 1 file changed, 10 insertions(+), 5 deletions(-)

[dpdk-dev] [PATCH v3 0/4] net/virtio: make virtqueue struct cache-friendly

2021-03-15 Thread Maxime Coquelin
This series optimizes the cache usage of virtqueue struct, by making a "fake" mbuf being dynamically allocated in Rx virtnet struct, by removing a useless virtuque pointer into the virtnet structs and by moving a few fields to pack holes. With these 3 patches, the virtqueue struct size goes from 5

[dpdk-dev] [PATCH v3 1/4] net/virtio: remove reference to virtqueue in vrings

2021-03-15 Thread Maxime Coquelin
Vrings are part of the virtqueues, so we don't need to have a pointer to it in Vrings descriptions. Instead, let's just subtract from its offset to calculate virtqueue address. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- drivers/net/virtio/virtio_ethdev.c| 36 +++

Re: [dpdk-dev] [PATCH v2] sched : Initialize tc ov watermark.

2021-03-15 Thread Coyle, David
> -Original Message- > From: dev On Behalf Of Savinay Dharmappa > Sent: Tuesday, March 9, 2021 4:10 PM > To: Singh, Jasvinder ; Dumitrescu, Cristian > ; dev@dpdk.org > Cc: Dharmappa, Savinay > Subject: [dpdk-dev] [PATCH v2] sched : Initialize tc ov watermark. > > tc ov watermark is ini

Re: [dpdk-dev] [PATCH v2 3/4] net/virtio: allocate fake mbuf in Rx queue

2021-03-15 Thread Maxime Coquelin
On 3/15/21 4:50 PM, David Marchand wrote: > On Mon, Mar 15, 2021 at 4:20 PM Maxime Coquelin > wrote: >> @@ -550,10 +551,18 @@ virtio_init_queue(struct rte_eth_dev *dev, uint16_t >> queue_idx) >> goto free_hdr_mz; >> } >> >> + fake_mbuf = ma

[dpdk-dev] [PATCH 2/2] net/mlx5: avoid unbind step to enable switchdev mode

2021-03-15 Thread Jan Viktorin
From: Jan Viktorin The step 4 is a contradiction. It advices to unbind the device from the mlx5_core which removes the associated system network interface (e.g. eth0). In the step 5, the same system network interface (e.g. eth0) is required to exist. Signed-off-by: Jan Viktorin --- doc/guides/

[dpdk-dev] [PATCH 1/2] net/mlx5: fix typos

2021-03-15 Thread Jan Viktorin
From: Jan Viktorin Signed-off-by: Jan Viktorin --- doc/guides/nics/mlx5.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/guides/nics/mlx5.rst b/doc/guides/nics/mlx5.rst index 7c50497fb..0a2dc3dee 100644 --- a/doc/guides/nics/mlx5.rst +++ b/doc/guides/nics/mlx5.rst

[dpdk-dev] [PATCH 7/7] doc: update sample actions support in mlx5 guide

2021-03-15 Thread Salem Sol
Updates the documentation with the added support for sample actions VXLAN and NVGRE encap in E-Switch steering flow. Signed-off-by: Salem Sol --- doc/guides/nics/mlx5.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/guides/nics/mlx5.rst b/doc/guides/nics/mlx5.rst i

[dpdk-dev] [PATCH 6/7] doc: update sample actions support in testpmd guide

2021-03-15 Thread Salem Sol
Update documentation for sample action usage in testpmd utilizing rte_flow_action_vxlan_encap and rte_flow_action_nvgre_encap and show the command line example. Signed-off-by: Salem Sol --- doc/guides/testpmd_app_ug/testpmd_funcs.rst | 21 + 1 file changed, 21 insertions(+)

[dpdk-dev] [PATCH 5/7] app/testpmd: support NVGRE encap for sample action

2021-03-15 Thread Salem Sol
Add support for rte_flow_action_nvge_encap as a sample action. The example of test-pmd command: 1. set nvgre ip-version ... tni ... ip-src ... ip-dst ... set raw_encap 1 eth src... / ipv4... /... set sample_actions 2 nvgre / port_id id 0 / end flow create 0 ... pattern eth / end acti

[dpdk-dev] [PATCH 3/7] net/mlx5: support NVGRE encap action in sample

2021-03-15 Thread Salem Sol
Add support for NVGRE encap as a sample action and validate it. Signed-off-by: Salem Sol --- drivers/net/mlx5/mlx5_flow_dv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c index 4b2db47e39..590abdc822 100644 --- a/drivers/n

[dpdk-dev] [PATCH 4/7] app/testpmd: support VXLAN encap for sample action

2021-03-15 Thread Salem Sol
Add support for rte_flow_action_vxlan_encap as a sample action. The example of test-pmd command: 1. set vxlan ip-version ... vni ... udp-src ... set raw_encap 1 eth src.../ ipv4.../... set sample_actions 2 vxlan_encap / port_id id 0 / end flow create 0 ... pattern eth / end actions

[dpdk-dev] [PATCH 2/7] net/mlx5: support VXLAN encap action in sample

2021-03-15 Thread Salem Sol
Add support for VXLAN encap as a sample action and validate it. Signed-off-by: Salem Sol --- drivers/net/mlx5/mlx5_flow_dv.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c index 1a74d5ac2b..4b2db47e39 100644 ---

[dpdk-dev] [PATCH 1/7] app/testpmd: store VXLAN/NVGRE encap data globally

2021-03-15 Thread Salem Sol
From: Jiawei Wang With the current code the VXLAN/NVGRE parsing routine stored the configuration of the header on stack, this might lead to overwriting the data on the stack. This patch stores the external data of vxlan and nvgre encap into global data as a pre-step to supporting vxlan and nvgre

[dpdk-dev] [PATCH 0/7] Add support for VXLAN and NVGRE encap as a sample actions

2021-03-15 Thread Salem Sol
This series adds support for VXLAN and NVGRE encap as a sample actions with the proper documentation, this series depends on [1] for the documentation part. [1] http://patches.dpdk.org/project/dpdk/patch/1615774238-51875-1-git-send-email-jiaw...@nvidia.com/ Jiawei Wang (1): app/testpmd: sto

Re: [dpdk-dev] [dpdk-stable] [PATCH v2] vhost: add header check in dequeue offload

2021-03-15 Thread David Marchand
On Mon, Mar 15, 2021 at 4:52 PM Xiao Wang wrote: > > When parsing the virtio net header and packet header for dequeue offload, > we need to perform sanity check on the packet header to ensure: > - No out-of-boundary memory access. > - The packet header and virtio_net header are valid and align

Re: [dpdk-dev] [PATCH 2/2] net/mlx5: avoid unbind step to enable switchdev mode

2021-03-15 Thread Jan Viktorin
Hello Salva, On Mon, 15 Mar 2021 15:53:51 + Slava Ovsiienko wrote: > Hi, Jan > > Yes, bullet [4] explicitly requires to unbind VFs, and detach the netdevs > from the mlx5_core driver. > Otherwise, kernel driver refuses to be configured with switchdev mode in [5]. > So, [4] can't be skippe

Re: [dpdk-dev] [PATCH v3 07/11] eal: add log level help

2021-03-15 Thread Stephen Hemminger
On Mon, 15 Mar 2021 11:52:13 +0100 Thomas Monjalon wrote: > 15/03/2021 11:42, Kinsella, Ray: > > > > On 15/03/2021 10:31, Bruce Richardson wrote: > > > On Mon, Mar 15, 2021 at 10:19:47AM +, Kinsella, Ray wrote: > > >> > > >> > > >> On 12/03/2021 18:17, Thomas Monjalon wrote: > > >>> Th

Re: [dpdk-dev] [PATCH v2 0/8] common/sfc_efx: prepare to introduce vDPA driver

2021-03-15 Thread Ferruh Yigit
On 3/15/2021 1:58 PM, Andrew Rybchenko wrote: Update base driver to provide functionality required by vDPA driver. Factor out helper functions to be shared by net and vDPA drivers. v2: - fix windows build breakage - do not build common/sfc_efx in the case of windows - remove undefined e

Re: [dpdk-dev] [PATCH 2/2] net/mlx5: avoid unbind step to enable switchdev mode

2021-03-15 Thread Slava Ovsiienko
Hi, Jan Yes, bullet [4] explicitly requires to unbind VFs, and detach the netdevs from the mlx5_core driver. Otherwise, kernel driver refuses to be configured with switchdev mode in [5]. So, [4] can't be skipped. After setting swithdev mode, VFs can be bound back (if it is needed, and these one

[dpdk-dev] [PATCH v2] vhost: add header check in dequeue offload

2021-03-15 Thread Xiao Wang
When parsing the virtio net header and packet header for dequeue offload, we need to perform sanity check on the packet header to ensure: - No out-of-boundary memory access. - The packet header and virtio_net header are valid and aligned. Fixes: d0cf91303d73 ("vhost: add Tx offload capabilitie

Re: [dpdk-dev] [PATCH v2 4/4] net/virtio: pack virtuqueue struct

2021-03-15 Thread David Marchand
On Mon, Mar 15, 2021 at 4:20 PM Maxime Coquelin wrote: > > This patch optimizes packing of the virtuqueue virtqueue ? and same typo in the title. > struct by moving fields around to fill holes. > > Offset field is not used and so can be removed. > > Signed-off-by: Maxime Coquelin > Reviewed-by:

Re: [dpdk-dev] [PATCH v2 3/4] net/virtio: allocate fake mbuf in Rx queue

2021-03-15 Thread David Marchand
On Mon, Mar 15, 2021 at 4:20 PM Maxime Coquelin wrote: > @@ -550,10 +551,18 @@ virtio_init_queue(struct rte_eth_dev *dev, uint16_t > queue_idx) > goto free_hdr_mz; > } > > + fake_mbuf = malloc(sizeof(*fake_mbuf)); > + if (!fake_m

Re: [dpdk-dev] [PATCH v2 2/4] net/virtio: improve queue init error path

2021-03-15 Thread Maxime Coquelin
On 3/15/21 4:38 PM, David Marchand wrote: > On Mon, Mar 15, 2021 at 4:20 PM Maxime Coquelin > wrote: >> @@ -604,15 +604,22 @@ virtio_init_queue(struct rte_eth_dev *dev, uint16_t >> queue_idx) >> >> if (VIRTIO_OPS(hw)->setup_queue(hw, vq) < 0) { >> PMD_INIT_LOG(ERR, "set

Re: [dpdk-dev] [PATCH v2 2/4] net/virtio: improve queue init error path

2021-03-15 Thread David Marchand
On Mon, Mar 15, 2021 at 4:20 PM Maxime Coquelin wrote: > @@ -604,15 +604,22 @@ virtio_init_queue(struct rte_eth_dev *dev, uint16_t > queue_idx) > > if (VIRTIO_OPS(hw)->setup_queue(hw, vq) < 0) { > PMD_INIT_LOG(ERR, "setup_queue failed"); > - return -EINVAL; >

Re: [dpdk-dev] [PATCH v4 1/2] eal: error number enhancement for thread TLS API

2021-03-15 Thread Tal Shnaiderman
> Subject: Re: [PATCH v4 1/2] eal: error number enhancement for thread TLS > API > > On Wed, Mar 10, 2021 at 02:48:55PM +0200, Tal Shnaiderman wrote: > > add error number reporting to rte_errno in all functions in the > > rte_thread_tls_* API. > > > > Suggested-by: Anatoly Burakov > > Signed-off-

[dpdk-dev] [PATCH v2] eal, power: use UINT64_MAX instead of -1ULL

2021-03-15 Thread Tyler Retzlaff
use UINT64_MAX instead of -1ULL when manipulating uint64_t masks and initializing sentinel values. some compilers generate a warning when applying a '-' to an unsigned literal so avoid this by initializing with unsigned preprocessor definitions where appropriate. Signed-off-by: Tyler Retzlaff --

[dpdk-dev] [PATCH] net/mlx5: add power monitoring support

2021-03-15 Thread Alexander Kozyrev
Support the PMD power management API in MLX5 driver. The monitor policy of this API puts a CPU core to sleep until a data in some monitored memory address is changed by the NIC. Implement the get_monitor_addr function to return an address of a CQE owner bit to monitor the arrival of a new packet.

Re: [dpdk-dev] [PATCH v11 2/2] bus/pci: support MMIO in PCI ioport accessors

2021-03-15 Thread 谢华伟(此时此刻)
On 2021/3/15 18:19, David Marchand wrote: #else #define IO_COND(addr, is_pio, is_mmio) do { \ is_mmio; \ } while (0) #endif We should not just copy/paste kernel code. Plus here, this seems a bit overkill. And there are other parts in thi

[dpdk-dev] [PATCH v2 4/4] net/virtio: pack virtuqueue struct

2021-03-15 Thread Maxime Coquelin
This patch optimizes packing of the virtuqueue struct by moving fields around to fill holes. Offset field is not used and so can be removed. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- drivers/net/virtio/virtqueue.h | 18 +- 1 file changed, 9 insertions(+), 9 del

[dpdk-dev] [PATCH v2 3/4] net/virtio: allocate fake mbuf in Rx queue

2021-03-15 Thread Maxime Coquelin
While it is worth clarifying whether the fake mbuf in virtnet_rx struct is really necessary, it is sure that it heavily impacts cache usage by being part of the struct. Indeed, it uses two cachelines, and requires alignement on a cacheline. Before this series, it means it took 120 bytes in virtnet

[dpdk-dev] [PATCH v2 1/4] net/virtio: remove reference to virtqueue in vrings

2021-03-15 Thread Maxime Coquelin
Vrings are part of the virtqueues, so we don't need to have a pointer to it in Vrings descriptions. Instead, let's just subtract from its offset to calculate virtqueue address. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- drivers/net/virtio/virtio_ethdev.c| 36 +++

[dpdk-dev] [PATCH v2 2/4] net/virtio: improve queue init error path

2021-03-15 Thread Maxime Coquelin
This patch improves the error path of virtio_init_queue(), by cleaning in reversing order all resources that have been allocated. Suggested-by: Chenbo Xia Signed-off-by: Maxime Coquelin --- drivers/net/virtio/virtio_ethdev.c | 19 +-- 1 file changed, 13 insertions(+), 6 deletion

[dpdk-dev] [PATCH v2 0/4] net/virtio: make virtqueue struct cache-friendly

2021-03-15 Thread Maxime Coquelin
This series optimizes the cache usage of virtqueue struct, by making a "fake" mbuf being dynamically allocated in Rx virtnet struct, by removing a useless virtuque pointer into the virtnet structs and by moving a few fields to pack holes. With these 3 patches, the virtqueue struct size goes from 5

Re: [dpdk-dev] [RFC] eventdev: introduce event dispatcher

2021-03-15 Thread Van Haaren, Harry
> -Original Message- > From: dev On Behalf Of Mattias Rönnblom > Sent: Monday, March 15, 2021 2:45 PM > To: Jerin Jacob > Cc: Jerin Jacob ; dpdk-dev ; Richardson, > Bruce > Subject: Re: [dpdk-dev] [RFC] eventdev: introduce event dispatcher > > On 2021-03-07 14:04, Jerin Jacob wrote: > >

Re: [dpdk-dev] [RFC] eventdev: introduce event dispatcher

2021-03-15 Thread Mattias Rönnblom
On 2021-03-07 14:04, Jerin Jacob wrote: > On Fri, Feb 26, 2021 at 1:31 PM Mattias Rönnblom > wrote: >> On 2021-02-25 13:32, Jerin Jacob wrote: >>> On Fri, Feb 19, 2021 at 12:00 AM Mattias Rönnblom >>> wrote: The purpose of the event dispatcher is primarily to decouple different parts of

Re: [dpdk-dev] [PATCH v2] update Intel roadmap for 21.05

2021-03-15 Thread Thomas Monjalon
10/03/2021 23:20, Ferruh Yigit: > Signed-off-by: Ferruh Yigit > --- > v2: > * there won't be a new driver for dlb2.5 > * reword thash library support Applied with minor updates for sorting things, thanks.

Re: [dpdk-dev] [PATCH v11 0/2] support both PIO and MMIO BAR for legacy virito device

2021-03-15 Thread David Marchand
On Wed, Mar 10, 2021 at 6:37 PM 谢华伟(此时此刻) wrote: > > virtio PMD assumes legacy device only supports PIO(port-mapped) BAR > resource. This is wrong. As we need to create lots of devices, adn PIO > resource on x86 is very limited, we expose MMIO(memory-mapped I/O) BAR. > > Kernel supports both PIO a

[dpdk-dev] [PATCH v2 8/8] drivers: add common driver API to get efx family

2021-03-15 Thread Andrew Rybchenko
From: Vijay Kumar Srivastava Move function to get efx family from net driver into common driver. Signed-off-by: Vijay Kumar Srivastava Signed-off-by: Andrew Rybchenko --- drivers/common/meson.build | 2 +- drivers/common/sfc_efx/meson.build | 5 +++ drivers/common/sfc_efx/sfc_efx.c

Re: [dpdk-dev] [PATCH 8/8] drivers: add common driver API to get efx family

2021-03-15 Thread Andrew Rybchenko
On 3/14/21 3:36 AM, Ferruh Yigit wrote: > On 3/11/2021 11:03 AM, Andrew Rybchenko wrote: >> From: Vijay Kumar Srivastava >> >> Move function to get efx family from net driver into common driver. >> >> Signed-off-by: Vijay Kumar Srivastava >> Signed-off-by: Andrew Rybchenko > > <...> > >> diff --

[dpdk-dev] [PATCH v2 6/8] common/sfc_efx: add support to get the device class

2021-03-15 Thread Andrew Rybchenko
From: Vijay Kumar Srivastava Device class argument would be used to select compatible driver. Driver probe would be skipped for incompatible device class. Signed-off-by: Vijay Kumar Srivastava Signed-off-by: Andrew Rybchenko --- drivers/common/sfc_efx/sfc_efx.c | 49

  1   2   >