[PATCH v4] crypto/qat: support to enable insecure algorithms

2023-05-25 Thread Vikash Poddar
All the insecure algorithms are default disable from cryptodev Gen 1,2,3 and 4. use qat_legacy_capa to enable all the legacy algorithms. These change effects both sym and asym insecure crypto algorithms. Signed-off-by: Vikash Poddar --- Depends-on: patch-28182 ("[v2] common/qat: fix qat_dev_cmd_p

RE: [PATCH v7] enhance NUMA affinity heuristic

2023-05-25 Thread You, KaisenX
> -Original Message- > From: Burakov, Anatoly > Sent: 2023年5月23日 18:45 > To: You, KaisenX ; dev@dpdk.org > Cc: Zhou, YidingX ; tho...@monjalon.net; > david.march...@redhat.com; Matz, Olivier ; > ferruh.yi...@amd.com; zhou...@loongson.cn; sta...@dpdk.org > Subject: Re: [PATCH v7] enhance

RE: [PATCH v3 05/10] net/cpfl: support hairpin queue setup and release

2023-05-25 Thread Xing, Beilei
> -Original Message- > From: Wu, Jingjing > Sent: Thursday, May 25, 2023 11:59 AM > To: Xing, Beilei > Cc: dev@dpdk.org; Liu, Mingxia ; Wang, Xiao W > > Subject: RE: [PATCH v3 05/10] net/cpfl: support hairpin queue setup and > release > > > > > +static int > > +cpfl_rx_hairpin_bufq_s

Re: [PATCH v1 1/1] doc: announce change in bbdev api related to operation extension

2023-05-25 Thread Stephen Hemminger
On Fri, 26 May 2023 02:11:32 + Nicolas Chautru wrote: > + > +* bbdev: Will extend the API to support the new operation type > ``RTE_BBDEV_OP_MLDTS`` as per > + this `v1 `. This > will also introduce > + new symbols for ``rte_bbdev_

RE: [PATCH v3 05/10] net/cpfl: support hairpin queue setup and release

2023-05-25 Thread Xing, Beilei
> -Original Message- > From: Liu, Mingxia > Sent: Wednesday, May 24, 2023 5:02 PM > To: Xing, Beilei ; Wu, Jingjing > Cc: dev@dpdk.org; Wang, Xiao W > Subject: RE: [PATCH v3 05/10] net/cpfl: support hairpin queue setup and > release > > > +cpfl_tx_hairpin_queue_setup(struct rte_eth_d

[PATCH v3] eal: fix eal init may failed when too much continuous memsegs under legacy mode

2023-05-25 Thread Fengnan Chang
Under legacy mode, if the number of continuous memsegs greater than RTE_MAX_MEMSEG_PER_LIST, eal init will failed even though another memseg list is empty, because only one memseg list used to check in remap_needed_hugepages. Fix this by make remap_segment return how many segments mapped, remap_seg

Re: [PATCH v3] usertools/telemetry: fix unused parameter

2023-05-25 Thread lihuisong (C)
在 2023/5/25 23:50, Samina Arshad 写道: This bug fix ensures that the runtime socket path is generated correctly, based on the user-specified file_prefix value, resolving the issue that occurred in the previous implementation. Fixes: a15fc792cfb6 ("usertools/telemetry: add file prefix argument")

Re: EXTERNAL] [PATCH ] Add checks for the port capabilties

2023-05-25 Thread Stephen Hemminger
On Fri, 26 May 2023 00:19:59 + Ajay Sharma wrote: > + dev_info->max_rx_queues = RTE_MIN(priv->max_rx_queues, USHRT_MAX); > + dev_info->max_tx_queues = RTE_MIN(priv->max_tx_queues, USHRT_MAX); > + Please use UINT16_MAX instead of USHRT_MAX since that is the type of max_rx_q

RE: [PATCH v2] app/testpmd: set srv6 header without any TLV

2023-05-25 Thread Rongwei Liu
HI @Ori Kam @NBU-Contact-Thomas Monjalon (EXTERNAL) @Andrew Rybchenko Can you share some comments on this? Thanks. BR Rongwei > -Original Message- > From: Rongwei Liu > Sent: Tuesday, March 28, 2023 20:28 > To: dev@dpdk.org; Matan Azrad ; Slava Ovsiienko > ; Ori Kam ; NBU

[PATCH] ethdev: fix indirect action convert

2023-05-25 Thread Suanming Mou
As indirect action conf fills the indirect action handler, while converting indirect action, the action conf(action handler) should be copied from original indirect action conf instead of duplicating the action handler memory. Fixes: 4b61b8774be9 ("ethdev: introduce indirect flow action") Signed-

[PATCH v2 9/9] crypto/mlx5: enable AES-GCM capability

2023-05-25 Thread Suanming Mou
This commit generates AES-GCM capability based on the NIC attributes and enables AES-GCM algo. An new devarg "algo" is added to identify if the crypto PMD will be initialized as AES-GCM(algo=1) or AES-XTS(algo=0, default). Signed-off-by: Suanming Mou --- doc/guides/cryptodevs/mlx5.rst |

[PATCH v2 7/9] crypto/mlx5: add queue pair setup for GCM

2023-05-25 Thread Suanming Mou
Crypto queue pair is for handling the encryption/decryption operations. As AES-GCM AEAD API provides AAD, mbuf, digest separately, low-level FW only accepts the data in a single contiguous memory region, two internal QPs are created for AES-GCM queue pair. One for organizing the memory to be conti

[PATCH v2 8/9] crypto/mlx5: add enqueue and dequeue operations

2023-05-25 Thread Suanming Mou
The crypto operations are performed with crypto WQE. If the input buffers(AAD, mbuf, digest) are not contiguous and there is no enough headroom/tailroom for copying AAD/digest, as the requirement from FW, an UMR WQE is needed to generate contiguous address space for crypto WQE. The UMR WQE and cryp

[PATCH v2 6/9] common/mlx5: add WQE-based QP synchronous basics

2023-05-25 Thread Suanming Mou
Nvidia HW provides a synchronous mechanism between QPs. When creating the QPs, user can set one as primary and another as follower. The follower QP's WQE execution can be controlled by primary QP via SEND_EN WQE. This commit introduces the SEND_EN WQE to improve the WQE execution sync-up between p

[PATCH v2 5/9] crypto/mlx5: add AES-GCM session configure

2023-05-25 Thread Suanming Mou
Sessions are used in symmetric transformations in order to prepare objects and data for packet processing stage. The AES-GCM session includes IV, AAD, digest(tag), DEK, operation mode information. Signed-off-by: Suanming Mou --- drivers/common/mlx5/mlx5_prm.h| 12 +++ drivers/crypto

[PATCH v2 4/9] crypto/mlx5: add AES-GCM encryption key

2023-05-25 Thread Suanming Mou
The crypto device requires the DEK(data encryption key) object for data encryption/decryption operation. This commit adds the AES-GCM DEK object management support. Signed-off-by: Suanming Mou --- drivers/crypto/mlx5/mlx5_crypto.h | 17 - drivers/crypto/mlx5/mlx5_crypto_dek.c | 102 +++

[PATCH v2 3/9] crypto/mlx5: add AES-GCM query and initialization

2023-05-25 Thread Suanming Mou
AES-GCM provides both authenticated encryption and the ability to check the integrity and authentication of additional authenticated data (AAD) that is sent in the clear. This commit adds the AES-GCM attributes query and initialization function. Signed-off-by: Suanming Mou --- drivers/common/ml

[PATCH v2 2/9] crypto/mlx5: split AES-XTS

2023-05-25 Thread Suanming Mou
As there will be other crypto algo be supported. This commit splits AES-XTS code to another *_xts.c file. The mlx5_crypto.c file will just contain the common code. Signed-off-by: Suanming Mou --- drivers/crypto/mlx5/meson.build | 1 + drivers/crypto/mlx5/mlx5_crypto.c | 642 ++---

[PATCH v2 1/9] common/mlx5: export memory region lookup by address

2023-05-25 Thread Suanming Mou
In case user provides the address without mempool. Export the function to lookup the address without mempool is required. Signed-off-by: Suanming Mou --- drivers/common/mlx5/mlx5_common_mr.c | 2 +- drivers/common/mlx5/mlx5_common_mr.h | 4 drivers/common/mlx5/version.map | 1 + 3 file

[PATCH v2 0/9] crypto/mlx5: support AES-GCM

2023-05-25 Thread Suanming Mou
AES-GCM provides both authenticated encryption and the ability to check the integrity and authentication of additional authenticated data (AAD) that is sent in the clear. The crypto operations are performed with crypto WQE. If the input buffers(AAD, mbuf, digest) are not contiguous and there is no

[PATCH v4 3/3] net/iavf: support Rx timestamp offload on SSE

2023-05-25 Thread Zhichao Zeng
This patch enables Rx timestamp offload on SSE data path. Enable timestamp offload with the command '--enable-rx-timestamp', pay attention that getting Rx timestamp offload will drop the performance. Signed-off-by: Zhichao Zeng --- v4: rework avx2 patch base on offload path --- v3: logging with

[PATCH v4 2/3] net/iavf: support Rx timestamp offload on AVX2

2023-05-25 Thread Zhichao Zeng
This patch enables Rx timestamp offload on AVX2 data path. Enable timestamp offload with the command '--enable-rx-timestamp', pay attention that getting Rx timestamp offload will drop the performance. Signed-off-by: Zhichao Zeng --- v4: rework avx2 patch base on offload path --- v3: logging wit

[PATCH v4 1/3] net/iavf: support Rx timestamp offload on AVX512

2023-05-25 Thread Zhichao Zeng
This patch enables Rx timestamp offload on AVX512 data path. Enable timestamp offload with the command '--enable-rx-timestamp', pay attention that getting Rx timestamp offload will drop the performance. Signed-off-by: Wenjun Wu Signed-off-by: Zhichao Zeng --- v4: rework avx2 patch base on offl

[PATCH v4 0/3] Enable iavf Rx Timestamp offload on vector path

2023-05-25 Thread Zhichao Zeng
Enable timestamp offload with the command '--enable-rx-timestamp', pay attention that getting Rx timestamp offload will drop the performance. --- v4: rework avx2 patch base on offload path --- v3: logging with driver dedicated macro --- v2: fix compile warning and SSE path Zhichao Zeng (3): net

[PATCH v1 1/1] doc: announce change in bbdev api related to operation extension

2023-05-25 Thread Nicolas Chautru
Intent to extend the bbdev api in DPDK 23.11 for new optional operations as well as addition of new members in existing structure. Signed-off-by: Nicolas Chautru --- doc/guides/rel_notes/deprecation.rst | 6 ++ 1 file changed, 6 insertions(+) diff --git a/doc/guides/rel_notes/deprecation.r

[PATCH v1 0/1] doc: accounce change in bbdev extension

2023-05-25 Thread Nicolas Chautru
Hi Maxime, Adding a deprecation notice for the change planning to be introduced in https://patches.dpdk.org/project/dpdk/list/?series=28192 Thanks Nicolas Nicolas Chautru (1): doc: announce change in bbdev api related to operation extension doc/guides/rel_notes/deprecation.rst | 6 ++ 1

RE: [PATCH v2] net/ice: DCF adds default RSS

2023-05-25 Thread Zhang, Qi Z
> -Original Message- > From: Ye, MingjinX > Sent: Wednesday, May 24, 2023 6:02 PM > To: dev@dpdk.org > Cc: Yang, Qiming ; Zhou, YidingX > ; Ye, MingjinX ; Zhang, Qi > Z > Subject: [PATCH v2] net/ice: DCF adds default RSS net/ice: add default RSS for DCF > > The default RSS configure

RE: [PATCH 0/2] add offload path on iavf AVX2

2023-05-25 Thread Zhang, Qi Z
> -Original Message- > From: Wenzhuo Lu > Sent: Tuesday, April 18, 2023 1:11 PM > To: dev@dpdk.org > Cc: Lu, Wenzhuo > Subject: [PATCH 0/2] add offload path on iavf AVX2 > > Add a specific path for RX/TX AVX2. > In this path, support the HW offload features, like, checksum, VLAN strip

[PATCH v3 2/2] test/crypto: Add SM3/SM4 test vectors for verification in test app

2023-05-25 Thread Sunyang Wu
Add SM3/SM4 test vectors for verification in test app. Signed-off-by: Sunyang Wu --- The test results of using openssl are as follows: + SM4 Chain : 24/24 passed, 0/24 skipped, 0/24 failed, 0/24 unsupported + SM4 Cipher Only : 10/10 passed, 0/10 skipped, 0/10 failed, 0/10 unsupported + Auth Only

[PATCH v3 1/2] cryptodev: support SM3_HMAC,SM4_CFB and SM4_OFB

2023-05-25 Thread Sunyang Wu
Add SM3_HMAC/SM4_CFB/SM4_OFB support in DPDK. Signed-off-by: Sunyang Wu --- doc/guides/cryptodevs/features/default.ini | 3 +++ doc/guides/rel_notes/release_23_07.rst | 5 + lib/cryptodev/rte_crypto_sym.h | 8 +++- lib/cryptodev/rte_cryptodev.c | 5 - 4 f

[Bug 1238] net/mlx5: RxQ failure with vectorized MPRQ

2023-05-25 Thread bugzilla
https://bugs.dpdk.org/show_bug.cgi?id=1238 Bug ID: 1238 Summary: net/mlx5: RxQ failure with vectorized MPRQ Product: DPDK Version: 23.03 Hardware: x86 OS: Linux Status: UNCONFIRMED Severity: normal

EXTERNAL] [PATCH ] Add checks for the port capabilties

2023-05-25 Thread Ajay Sharma
From: Ajay Sharma Date: Mon, 22 May 2023 20:24:39 -0700 Subject: [PATCH] Add checks for the port capabilties Add checks to the values retrieved from the firmware to prevent overflow. Signed-off-by: Ajay Sharma --- drivers/net/mana/mana.c | 18 ++ 1 file chan

[PATCH v1 3/4] bbdev: add new capability for FEC 5G UL processing

2023-05-25 Thread Nicolas Chautru
Extending existing LDPC UL operation for new capability. Option to compress HARQ memory to 4 bits per LLR. Signed-off-by: Nicolas Chautru --- doc/guides/prog_guide/bbdev.rst | 6 ++ lib/bbdev/rte_bbdev_op.h| 4 +++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/doc/gu

[PATCH v1 4/4] bbdev: improving error handling for queue configuration

2023-05-25 Thread Nicolas Chautru
Refactor of the error handling based on available priority queue to be more generic. Signed-off-by: Nicolas Chautru --- lib/bbdev/rte_bbdev.c | 15 ++- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/lib/bbdev/rte_bbdev.c b/lib/bbdev/rte_bbdev.c index 26fc077bdc..589b79

[PATCH v1 1/4] bbdev: add operation type for MLDTS procession

2023-05-25 Thread Nicolas Chautru
Extended bbdev operations to support MLDTS based operations. Signed-off-by: Nicolas Chautru --- doc/guides/prog_guide/bbdev.rst | 53 +++ lib/bbdev/rte_bbdev.c | 11 ++- lib/bbdev/rte_bbdev.h | 76 + lib/bbdev/rte_bbdev_op.h| 116 +++

[PATCH v1 2/4] bbdev: add new capabilities for FFT processing

2023-05-25 Thread Nicolas Chautru
Extending existing FFT operation for new capabilities. Optional frequency domain dewindowing, frequency resampling, timing error correction and time offset per CS. Signed-off-by: Nicolas Chautru --- doc/guides/prog_guide/bbdev.rst | 24 lib/bbdev/rte_bbdev_op.h|

[PATCH v1 0/4] bbdev: API extension for 23.11

2023-05-25 Thread Nicolas Chautru
Hi, Including v1 for extending the bbdev api for 23.11. The new MLD-TS is expected to be non ABI compatible, the other ones should not break ABI. I will send a deprecation notice in parallel. This introduces a new operation (on top of FEC and FFT) to support equalization for MLD-TS. There also

[PATCH] ethdev: validate reserved fields

2023-05-25 Thread Stephen Hemminger
The various reserved fields added to ethdev could not be safely used for future extensions because they were never checked on input. Therefore ABI would be broken if these fields were added in a future DPDK release. Fixes: 436b3a6b6e62 ("ethdev: reserve space in main structs for extension") Cc: th

Re: [PATCH v17] app/procinfo: display eventdev xstats

2023-05-25 Thread Stephen Hemminger
On Thu, 25 May 2023 13:47:31 -0500 Abdullah Sevincer wrote: > This commit extends proc-info application to > display xstats for the eventdev devices. > > New command line arguments are introduced to > display xstats for eventdev devices. The command > example is like: > > For displaying a speci

[PATCH v17] app/procinfo: display eventdev xstats

2023-05-25 Thread Abdullah Sevincer
This commit extends proc-info application to display xstats for the eventdev devices. New command line arguments are introduced to display xstats for eventdev devices. The command example is like: For displaying a specific port stats (e.g. port 1): ./dpdk-proc-info -- --show-edev-port-xstats=1:0

[PATCH v2 5/6] baseband/fpga_5gnr_fec: add AGX100 support

2023-05-25 Thread Hernan Vargas
Add support for new FPGA variant AGX100 (on Arrow Creek N6000). Signed-off-by: Hernan Vargas --- doc/guides/bbdevs/fpga_5gnr_fec.rst | 72 +- drivers/baseband/fpga_5gnr_fec/agx100_pmd.h | 273 .../baseband/fpga_5gnr_fec/fpga_5gnr_fec.h|6 + .../fpga_5gnr_fec/rte_fpga_

[PATCH v2 4/6] baseband/fpga_5gnr_fec: add Vista Creek variant

2023-05-25 Thread Hernan Vargas
Create a new file vc_5gnr_pmd.h to store structures and macros specific to Vista Creek 5G FPGA implementation and rename functions specific to the Vista Creek variant. Signed-off-by: Hernan Vargas --- .../baseband/fpga_5gnr_fec/fpga_5gnr_fec.h| 183 +- .../fpga_5gnr_fec/rte_fpga_5gnr_fec

[PATCH v2 6/6] baseband/fpga_5gnr_fec: cosmetic comment changes

2023-05-25 Thread Hernan Vargas
Cosmetic changes for comments. No functional impact. Signed-off-by: Hernan Vargas --- .../baseband/fpga_5gnr_fec/fpga_5gnr_fec.h| 93 ++-- .../fpga_5gnr_fec/rte_fpga_5gnr_fec.c | 398 +- .../fpga_5gnr_fec/rte_pmd_fpga_5gnr_fec.h | 16 +- 3 files changed, 252 ins

[PATCH v2 3/6] baseband/fpga_5gnr_fec: renaming for consistency

2023-05-25 Thread Hernan Vargas
Rename generic functions and constants using the FPGA 5GNR prefix naming to prepare for code reuse for new FPGA implementation variant. No functional impact. Signed-off-by: Hernan Vargas --- .../baseband/fpga_5gnr_fec/fpga_5gnr_fec.h| 117 +++-- .../fpga_5gnr_fec/rte_fpga_5gnr_fec.c

[PATCH v2 2/6] baseband/fpga_5gnr_fec: fix seg fault unconf queue

2023-05-25 Thread Hernan Vargas
Adding exception to prevent segmentation fault in case a queue is started which was not configured earlier. Fixes: c58109a8871d ("baseband/fpga_5gnr_fec: add queue configuration") Cc: sta...@dpdk.org Signed-off-by: Hernan Vargas Reviewed-by: Maxime Coquelin --- drivers/baseband/fpga_5gnr_fec/r

[PATCH v2 1/6] baseband/fpga_5gnr_fec: fix possible div by zero

2023-05-25 Thread Hernan Vargas
Add fix to have an early exit when z_c is zero to prevent a possible division by zero. Fixes: 44dc6faa796f ("baseband/fpga_5gnr_fec: add LDPC processing functions") Cc: sta...@dpdk.org Signed-off-by: Hernan Vargas Reviewed-by: Maxime Coquelin --- drivers/baseband/fpga_5gnr_fec/rte_fpga_5gnr_fe

[PATCH v2 0/6] changes for 23.07

2023-05-25 Thread Hernan Vargas
v2: Targeting 23.11. Update in commits 1,2 based on review comments. v1: Targeting 23.07 if possible. Add support for AGX100 (N6000) and corner case fixes. Hernan Vargas (6): baseband/fpga_5gnr_fec: fix possible div by zero baseband/fpga_5gnr_fec: fix seg fault unconf queue baseband/fpga_5g

Re: [RFC v2 1/2] dts: add smoke tests

2023-05-25 Thread Jeremy Spewock
Hey Juraj, On Thu, May 25, 2023 at 4:33 AM Juraj Linkeš wrote: > One more point that doesn't fit elsewhere: > > On Wed, May 24, 2023 at 10:45 PM Jeremy Spewock > wrote: > > > > > > > > On Tue, May 23, 2023 at 4:05 AM Juraj Linkeš > wrote: > >> > >> Hi Jeremy, first, a few general points: > >>

RE: [PATCH v16] app/procinfo: display eventdev xstats

2023-05-25 Thread Sevincer, Abdullah
>+ I was thinking of helper function and using const strings. >+ Don't need to panic on invalid eventdev. >+ Also the flags could be just bitfield to save some space. >+ Something like this. Untested since I have no hardware with >+ eventdevs. Thanks Stephen, Let me revise more with your sugge

Re: [PATCH v16] app/procinfo: display eventdev xstats

2023-05-25 Thread Stephen Hemminger
On Thu, 25 May 2023 11:41:27 -0500 Abdullah Sevincer wrote: > This commit extends proc-info application to > display xstats for the eventdev devices. > > New command line arguments are introduced to > display xstats for eventdev devices. The command > example is like: > > For displaying a speci

[PATCH v16] app/procinfo: display eventdev xstats

2023-05-25 Thread Abdullah Sevincer
This commit extends proc-info application to display xstats for the eventdev devices. New command line arguments are introduced to display xstats for eventdev devices. The command example is like: For displaying a specific port stats (e.g. port 1): ./dpdk-proc-info -- --show-edev-port-xstats=1:0

[PATCH v3 27/28] vhost: add multiqueue support to VDUSE

2023-05-25 Thread Maxime Coquelin
This patch enables control queue support in order to support multiqueue. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 83 +++ 1 file changed, 76 insertions(+), 7 deletions(-) diff --git a/lib/vhost/vduse.c b/lib/vhos

[PATCH v3 28/28] vhost: add VDUSE device stop

2023-05-25 Thread Maxime Coquelin
This patch adds VDUSE device stop and cleanup of its virtqueues. Signed-off-by: Maxime Coquelin --- doc/guides/rel_notes/release_23_07.rst | 6 +++ lib/vhost/vduse.c | 72 +++--- 2 files changed, 70 insertions(+), 8 deletions(-) diff --git a/doc/guides/

[PATCH v3 26/28] vhost: add VDUSE device startup

2023-05-25 Thread Maxime Coquelin
This patch adds the device and its virtqueues initialization once the Virtio driver has set the DRIVER_OK in the Virtio status register. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 126 ++ 1 file changed, 126 inserti

[PATCH v3 24/28] vhost: add support for VDUSE status set event

2023-05-25 Thread Maxime Coquelin
This patch adds support for VDUSE_SET_STATUS event handling, which consists in updating the Virtio device status set by the Virtio driver. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/lib/vhost/vduse.c b/l

[PATCH v3 25/28] vhost: add support for VDUSE IOTLB update event

2023-05-25 Thread Maxime Coquelin
This patch adds support for VDUSE_UPDATE_IOTLB event handling, which consists in invaliding IOTLB entries for the range specified in the request. Signed-off-by: Maxime Coquelin --- lib/vhost/vduse.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/lib/vhost/vduse.c b/lib/vhost/vduse.c

[PATCH v3 23/28] vhost: add support for virtqueue state get event

2023-05-25 Thread Maxime Coquelin
This patch adds support for VDUSE_GET_VQ_STATE event handling, which consists in providing the backend last available index for the specified virtqueue. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 8 1 file changed, 8 insertions(+) diff --git a/lib/v

[PATCH v3 22/28] vhost: add VDUSE events handler

2023-05-25 Thread Maxime Coquelin
This patch makes use of Vhost lib's FD manager to install a handler for VDUSE events occurring on the VDUSE device FD. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 101 ++ 1 file changed, 101 insertions(+) diff --git

[PATCH v3 20/28] vhost: add VDUSE callback for IOTLB entry removal

2023-05-25 Thread Maxime Coquelin
This patch implements the VDUSE callback for IOTLB entry removal, where it unmaps the pages from the invalidated IOTLB entry. Signed-off-by: Maxime Coquelin --- lib/vhost/vduse.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/lib/vhost/vduse.c b/lib/vhost/vduse.c index f72c7bf6ab..58

[PATCH v3 21/28] vhost: add VDUSE callback for IRQ injection

2023-05-25 Thread Maxime Coquelin
This patch implements the VDUSE callback for kicking virtqueues. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/lib/vhost/vduse.c b/lib/vhost/vduse.c index 58c1b384a8..d39e39b9dc 100644 --- a/lib/vhost/vdus

[PATCH v3 19/28] vhost: add VDUSE callback for IOTLB miss

2023-05-25 Thread Maxime Coquelin
This patch implements the VDUSE callback for IOTLB misses, which is done by using the VDUSE VDUSE_IOTLB_GET_FD ioctl. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 58 +++ 1 file changed, 58 insertions(+) diff --git a

[PATCH v3 18/28] vhost: add VDUSE device creation and destruction

2023-05-25 Thread Maxime Coquelin
This patch adds initial support for VDUSE, which includes the device creation and destruction. It does not include the virtqueues configuration, so this is not functionnal at this point. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/meson.build | 4 + lib/vhost/socket.

[PATCH v3 17/28] vhost: add control virtqueue support

2023-05-25 Thread Maxime Coquelin
In order to support multi-queue with VDUSE, having control queue support is required. This patch adds control queue implementation, it will be used later when adding VDUSE support. Only split ring layout is supported for now, packed ring support will be added later. Signed-off-by: Maxime Coquelin

[PATCH v3 16/28] net/vhost: use API to set max queue pairs

2023-05-25 Thread Maxime Coquelin
In order to support multiqueue with VDUSE, we need to be able to limit the maximum number of queue pairs, to avoid unnecessary memory consumption since the maximum number of queue pairs need to be allocated at device creation time, as opposed to Vhost-user which allocate only when the frontend init

[PATCH v3 15/28] vhost: add API to set max queue pairs

2023-05-25 Thread Maxime Coquelin
This patch introduces a new rte_vhost_driver_set_max_queues API as preliminary work for multiqueue support with VDUSE. Indeed, with VDUSE we need to pre-allocate the vrings at device creation time, so we need such API not to allocate the 128 queue pairs supported by the Vhost library. Calling the

[PATCH v3 14/28] vhost: add helper for interrupt injection

2023-05-25 Thread Maxime Coquelin
Vhost-user uses eventfd to inject IRQs, but VDUSE uses an ioctl. This patch prepares vhost_vring_call_split() and vhost_vring_call_packed() to support VDUSE by introducing a new helper. It also adds a new counter for guest notification failures, which could happen in case of uninitialized call fi

[PATCH v3 13/28] vhost: add helper for IOTLB misses

2023-05-25 Thread Maxime Coquelin
This patch adds a helper for sending IOTLB misses as VDUSE will use an ioctl while Vhost-user use a dedicated Vhost-user backend request. Signed-off-by: Maxime Coquelin --- lib/vhost/vhost.c | 13 - lib/vhost/vhost.h | 4 lib/vhost/vhost_user.c | 6 -- lib/vhost/

[PATCH v3 12/28] vhost: add IOTLB cache entry removal callback

2023-05-25 Thread Maxime Coquelin
VDUSE will need to munmap() the IOTLB entry on removal from the cache, as it performs mmap() before insertion. This patch introduces a callback that VDUSE layer will implement to achieve this. Signed-off-by: Maxime Coquelin --- lib/vhost/iotlb.c | 12 lib/vhost/vhost.h | 3 +++ 2

[PATCH v3 08/28] vhost: add offset field to IOTLB entries

2023-05-25 Thread Maxime Coquelin
This patch is a preliminary work to prepare for VDUSE support, for which we need to keep track of the mmaped base address and offset in order to be able to unmap it later when IOTLB entry is invalidated. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/iotlb.c | 30

[PATCH v3 11/28] vhost: introduce backend ops

2023-05-25 Thread Maxime Coquelin
This patch introduces backend ops struct, that will enable calling backend specifics callbacks (Vhost-user, VDUSE), in shared code. This is an empty shell for now, it will be filled in later patches. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/socket.c | 2 +- lib

[PATCH v3 10/28] vhost: retry translating IOVA after IOTLB miss

2023-05-25 Thread Maxime Coquelin
Vhost-user backend IOTLB misses and updates are asynchronous, so IOVA address translation function just fails after having sent an IOTLB miss update if needed entry was not in the IOTLB cache. This is not the case for VDUSE, for which the needed IOTLB update is returned directly when sending an IO

[PATCH v3 09/28] vhost: add page size info to IOTLB entry

2023-05-25 Thread Maxime Coquelin
VDUSE will close the file descriptor after having mapped the shared memory, so it will not be possible to get the page size afterwards. This patch adds an new page_shift field to the IOTLB entry, so that the information will be passed at IOTLB cache insertion time. The information is stored as a b

[PATCH v3 06/28] vhost: don't dump unneeded pages with IOTLB

2023-05-25 Thread Maxime Coquelin
On IOTLB entry removal, previous fixes took care of not marking pages shared with other IOTLB entries as DONTDUMP. However, if an IOTLB entry is spanned on multiple pages, the other pages were kept as DODUMP while they might not have been shared with other entries, increasing needlessly the coredu

[PATCH v3 07/28] vhost: change to single IOTLB cache per device

2023-05-25 Thread Maxime Coquelin
This patch simplifies IOTLB implementation and improves IOTLB memory consumption by having a single IOTLB cache per device, instead of having one per queue. In order to not impact performance, it keeps an IOTLB lock per virtqueue, so that there is no contention between multiple queue trying to acq

[PATCH v3 05/28] vhost: add helper for IOTLB entries shared page check

2023-05-25 Thread Maxime Coquelin
This patch introduces a helper to check whether two IOTLB entries share a page. Signed-off-by: Maxime Coquelin Acked-by: Mike Pattrick Reviewed-by: Chenbo Xia --- lib/vhost/iotlb.c | 25 - 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/lib/vhost/iotlb.c

[PATCH v3 04/28] vhost: add helper of IOTLB entries coredump

2023-05-25 Thread Maxime Coquelin
This patch reworks IOTLB code to extract madvise-related bits into dedicated helper. This refactoring improves code sharing. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/iotlb.c | 77 +-- 1 file changed, 41 insertions(+), 36 de

[PATCH v3 03/28] vhost: fix IOTLB entries overlap check with previous entry

2023-05-25 Thread Maxime Coquelin
Commit 22b6d0ac691a ("vhost: fix madvise IOTLB entries pages overlap check") fixed the check to ensure the entry to be removed does not overlap with the next one in the IOTLB cache before marking it as DONTDUMP with madvise(). This is not enough, because the same issue is present when comparing wit

[PATCH v3 02/28] vhost: fix invalid call FD handling

2023-05-25 Thread Maxime Coquelin
This patch fixes cases where IRQ injection is tried while the call FD is not valid, which should not happen. Fixes: b1cce26af1dc ("vhost: add notification for packed ring") Fixes: e37ff954405a ("vhost: support virtqueue interrupt/notification suppression") Cc: sta...@dpdk.org Signed-off-by: Maxi

[PATCH v3 01/28] vhost: fix missing guest notif stat increment

2023-05-25 Thread Maxime Coquelin
Guest notification counter was only incremented for split ring, this patch adds it also for packed ring. Fixes: 1ea74efd7fa4 ("vhost: add statistics for guest notification") Cc: sta...@dpdk.org Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vhost.h | 2 ++ 1 file changed,

[PATCH v3 00/28] Add VDUSE support to Vhost library

2023-05-25 Thread Maxime Coquelin
Note: v2 is identical to v3, it is just a resend because of an issue when posting v2 breaking the series in patchwork. This series introduces a new type of backend, VDUSE, to the Vhost library. VDUSE stands for vDPA device in Userspace, it enables implementing a Virtio device in userspace and hav

Re: [PATCH 28/28] vhost: Add VDUSE device stop

2023-05-25 Thread Maxime Coquelin
Sorry, something went wrong when sending the series. I'm sending a v3 as the series is broken in two in patchwork because of this leftover patch. On 5/25/23 18:15, Maxime Coquelin wrote: This patch adds VDUSE device stop and cleanup of its virtqueues. Signed-off-by: Maxime Coquelin --- doc/g

[PATCH v2 28/28] vhost: add VDUSE device stop

2023-05-25 Thread Maxime Coquelin
This patch adds VDUSE device stop and cleanup of its virtqueues. Signed-off-by: Maxime Coquelin --- doc/guides/rel_notes/release_23_07.rst | 6 +++ lib/vhost/vduse.c | 72 +++--- 2 files changed, 70 insertions(+), 8 deletions(-) diff --git a/doc/guides/

[PATCH 28/28] vhost: Add VDUSE device stop

2023-05-25 Thread Maxime Coquelin
This patch adds VDUSE device stop and cleanup of its virtqueues. Signed-off-by: Maxime Coquelin --- doc/guides/rel_notes/release_23_07.rst | 6 +++ lib/vhost/vduse.c | 72 +++--- 2 files changed, 70 insertions(+), 8 deletions(-) diff --git a/doc/guides/

[PATCH v2 27/28] vhost: add multiqueue support to VDUSE

2023-05-25 Thread Maxime Coquelin
This patch enables control queue support in order to support multiqueue. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 83 +++ 1 file changed, 76 insertions(+), 7 deletions(-) diff --git a/lib/vhost/vduse.c b/lib/vhos

[PATCH v2 25/28] vhost: add support for VDUSE IOTLB update event

2023-05-25 Thread Maxime Coquelin
This patch adds support for VDUSE_UPDATE_IOTLB event handling, which consists in invaliding IOTLB entries for the range specified in the request. Signed-off-by: Maxime Coquelin --- lib/vhost/vduse.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/lib/vhost/vduse.c b/lib/vhost/vduse.c

[PATCH v2 26/28] vhost: add VDUSE device startup

2023-05-25 Thread Maxime Coquelin
This patch adds the device and its virtqueues initialization once the Virtio driver has set the DRIVER_OK in the Virtio status register. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 126 ++ 1 file changed, 126 inserti

[PATCH v2 24/28] vhost: add support for VDUSE status set event

2023-05-25 Thread Maxime Coquelin
This patch adds support for VDUSE_SET_STATUS event handling, which consists in updating the Virtio device status set by the Virtio driver. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/lib/vhost/vduse.c b/l

[PATCH v2 23/28] vhost: add support for virtqueue state get event

2023-05-25 Thread Maxime Coquelin
This patch adds support for VDUSE_GET_VQ_STATE event handling, which consists in providing the backend last available index for the specified virtqueue. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 8 1 file changed, 8 insertions(+) diff --git a/lib/v

[PATCH v2 22/28] vhost: add VDUSE events handler

2023-05-25 Thread Maxime Coquelin
This patch makes use of Vhost lib's FD manager to install a handler for VDUSE events occurring on the VDUSE device FD. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 101 ++ 1 file changed, 101 insertions(+) diff --git

[PATCH v2 21/28] vhost: add VDUSE callback for IRQ injection

2023-05-25 Thread Maxime Coquelin
This patch implements the VDUSE callback for kicking virtqueues. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/lib/vhost/vduse.c b/lib/vhost/vduse.c index 58c1b384a8..d39e39b9dc 100644 --- a/lib/vhost/vdus

[PATCH v2 20/28] vhost: add VDUSE callback for IOTLB entry removal

2023-05-25 Thread Maxime Coquelin
This patch implements the VDUSE callback for IOTLB entry removal, where it unmaps the pages from the invalidated IOTLB entry. Signed-off-by: Maxime Coquelin --- lib/vhost/vduse.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/lib/vhost/vduse.c b/lib/vhost/vduse.c index f72c7bf6ab..58

[PATCH v2 19/28] vhost: add VDUSE callback for IOTLB miss

2023-05-25 Thread Maxime Coquelin
This patch implements the VDUSE callback for IOTLB misses, which is done by using the VDUSE VDUSE_IOTLB_GET_FD ioctl. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/vduse.c | 58 +++ 1 file changed, 58 insertions(+) diff --git a

[PATCH v2 18/28] vhost: add VDUSE device creation and destruction

2023-05-25 Thread Maxime Coquelin
This patch adds initial support for VDUSE, which includes the device creation and destruction. It does not include the virtqueues configuration, so this is not functionnal at this point. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/meson.build | 4 + lib/vhost/socket.

[PATCH v2 17/28] vhost: add control virtqueue support

2023-05-25 Thread Maxime Coquelin
In order to support multi-queue with VDUSE, having control queue support is required. This patch adds control queue implementation, it will be used later when adding VDUSE support. Only split ring layout is supported for now, packed ring support will be added later. Signed-off-by: Maxime Coquelin

[PATCH v2 14/28] vhost: add helper for interrupt injection

2023-05-25 Thread Maxime Coquelin
Vhost-user uses eventfd to inject IRQs, but VDUSE uses an ioctl. This patch prepares vhost_vring_call_split() and vhost_vring_call_packed() to support VDUSE by introducing a new helper. It also adds a new counter for guest notification failures, which could happen in case of uninitialized call fi

[PATCH v2 16/28] net/vhost: use API to set max queue pairs

2023-05-25 Thread Maxime Coquelin
In order to support multiqueue with VDUSE, we need to be able to limit the maximum number of queue pairs, to avoid unnecessary memory consumption since the maximum number of queue pairs need to be allocated at device creation time, as opposed to Vhost-user which allocate only when the frontend init

[PATCH v2 15/28] vhost: add API to set max queue pairs

2023-05-25 Thread Maxime Coquelin
This patch introduces a new rte_vhost_driver_set_max_queues API as preliminary work for multiqueue support with VDUSE. Indeed, with VDUSE we need to pre-allocate the vrings at device creation time, so we need such API not to allocate the 128 queue pairs supported by the Vhost library. Calling the

[PATCH v2 12/28] vhost: add IOTLB cache entry removal callback

2023-05-25 Thread Maxime Coquelin
VDUSE will need to munmap() the IOTLB entry on removal from the cache, as it performs mmap() before insertion. This patch introduces a callback that VDUSE layer will implement to achieve this. Signed-off-by: Maxime Coquelin --- lib/vhost/iotlb.c | 12 lib/vhost/vhost.h | 3 +++ 2

[PATCH v2 11/28] vhost: introduce backend ops

2023-05-25 Thread Maxime Coquelin
This patch introduces backend ops struct, that will enable calling backend specifics callbacks (Vhost-user, VDUSE), in shared code. This is an empty shell for now, it will be filled in later patches. Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/vhost/socket.c | 2 +- lib

[PATCH v2 13/28] vhost: add helper for IOTLB misses

2023-05-25 Thread Maxime Coquelin
This patch adds a helper for sending IOTLB misses as VDUSE will use an ioctl while Vhost-user use a dedicated Vhost-user backend request. Signed-off-by: Maxime Coquelin --- lib/vhost/vhost.c | 13 - lib/vhost/vhost.h | 4 lib/vhost/vhost_user.c | 6 -- lib/vhost/

  1   2   3   >