* [dpdk-dev] [PATCH 0/5] Support MLX5 crypto driver on Windows
@ 2021-10-12 15:53 Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 1/5] common/mlx5: add DV enums to Windows defs file Tal Shnaiderman
` (4 more replies)
0 siblings, 5 replies; 8+ messages in thread
From: Tal Shnaiderman @ 2021-10-12 15:53 UTC (permalink / raw)
To: dev
Cc: thomas, matan, rasland, asafp, gakhil, declan.doherty,
viacheslavo, eilong
Support the MLX5 crypto driver on Windows OS by moving the driver's
control path communication with the Kernel to be OS agnostic.
---
Depends-on: series-19421 ("mlx5: sharing global MR cache between drivers")
---
Tal Shnaiderman (5):
common/mlx5: add DV enums to Windows defs file
crypto/mlx5: replace UNIX functions with EAL functions
crypto/mlx5: use OS agnostic functions for UMEM operations
crypto/mlx5: fix size of UMR WQE
crypto/mlx5: support on Windows
doc/guides/cryptodevs/mlx5.rst | 15 ++++++++++++---
doc/guides/rel_notes/release_21_11.rst | 1 +
drivers/common/mlx5/version.map | 2 +-
drivers/common/mlx5/windows/mlx5_common_os.c | 2 +-
drivers/common/mlx5/windows/mlx5_win_defs.h | 12 ++++++++++++
drivers/crypto/aesni_gcm/meson.build | 6 ++++++
drivers/crypto/aesni_mb/meson.build | 6 ++++++
drivers/crypto/armv8/meson.build | 6 ++++++
drivers/crypto/bcmfs/meson.build | 6 ++++++
drivers/crypto/ccp/meson.build | 1 +
drivers/crypto/kasumi/meson.build | 6 ++++++
drivers/crypto/meson.build | 3 ---
drivers/crypto/mlx5/meson.build | 4 ++--
drivers/crypto/mlx5/mlx5_crypto.c | 18 +++++++++++-------
drivers/crypto/mlx5/mlx5_crypto.h | 2 +-
drivers/crypto/mvsam/meson.build | 6 ++++++
drivers/crypto/null/meson.build | 6 ++++++
drivers/crypto/octeontx/meson.build | 6 ++++++
drivers/crypto/openssl/meson.build | 6 ++++++
drivers/crypto/qat/meson.build | 6 ++++++
drivers/crypto/scheduler/meson.build | 6 ++++++
drivers/crypto/snow3g/meson.build | 6 ++++++
drivers/crypto/virtio/meson.build | 6 ++++++
drivers/crypto/zuc/meson.build | 6 ++++++
24 files changed, 126 insertions(+), 18 deletions(-)
--
2.16.1.windows.4
^ permalink raw reply [flat|nested] 8+ messages in thread
* [dpdk-dev] [PATCH 1/5] common/mlx5: add DV enums to Windows defs file
2021-10-12 15:53 [dpdk-dev] [PATCH 0/5] Support MLX5 crypto driver on Windows Tal Shnaiderman
@ 2021-10-12 15:53 ` Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 2/5] crypto/mlx5: replace UNIX functions with EAL functions Tal Shnaiderman
` (3 subsequent siblings)
4 siblings, 0 replies; 8+ messages in thread
From: Tal Shnaiderman @ 2021-10-12 15:53 UTC (permalink / raw)
To: dev
Cc: thomas, matan, rasland, asafp, gakhil, declan.doherty,
viacheslavo, eilong
Add needed DV enums used by the crypto PMD and missing
for Windows OS.
Signed-off-by: Tal Shnaiderman <talshn@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
drivers/common/mlx5/windows/mlx5_win_defs.h | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/drivers/common/mlx5/windows/mlx5_win_defs.h b/drivers/common/mlx5/windows/mlx5_win_defs.h
index 47bfc907e7..9f709ff30d 100644
--- a/drivers/common/mlx5/windows/mlx5_win_defs.h
+++ b/drivers/common/mlx5/windows/mlx5_win_defs.h
@@ -93,6 +93,18 @@ enum {
MLX5_ETH_WQE_L4_CSUM = (1 << 7),
};
+enum {
+ MLX5_WQE_CTRL_CQ_UPDATE = 2 << 2,
+ MLX5_WQE_CTRL_SOLICITED = 1 << 1,
+ MLX5_WQE_CTRL_FENCE = 4 << 5,
+ MLX5_WQE_CTRL_INITIATOR_SMALL_FENCE = 1 << 5,
+};
+
+enum {
+ MLX5_SEND_WQE_BB = 64,
+ MLX5_SEND_WQE_SHIFT = 6,
+};
+
/*
* RX Hash fields enable to set which incoming packet's field should
* participates in RX Hash. Each flag represent certain packet's field,
--
2.16.1.windows.4
^ permalink raw reply [flat|nested] 8+ messages in thread
* [dpdk-dev] [PATCH 2/5] crypto/mlx5: replace UNIX functions with EAL functions
2021-10-12 15:53 [dpdk-dev] [PATCH 0/5] Support MLX5 crypto driver on Windows Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 1/5] common/mlx5: add DV enums to Windows defs file Tal Shnaiderman
@ 2021-10-12 15:53 ` Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 3/5] crypto/mlx5: use OS agnostic functions for UMEM operations Tal Shnaiderman
` (2 subsequent siblings)
4 siblings, 0 replies; 8+ messages in thread
From: Tal Shnaiderman @ 2021-10-12 15:53 UTC (permalink / raw)
To: dev
Cc: thomas, matan, rasland, asafp, gakhil, declan.doherty,
viacheslavo, eilong
Use the OS agnostic EAL function rte_mem_page_size to get
page size value instead of the Linux specific implementation.
Also remove the usage of PTHREAD_MUTEX_INITIALIZER which is not
support in Windows and initialize priv_list_lock in RTE_INIT.
Signed-off-by: Tal Shnaiderman <talshn@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
drivers/crypto/mlx5/mlx5_crypto.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/crypto/mlx5/mlx5_crypto.c b/drivers/crypto/mlx5/mlx5_crypto.c
index 2af5194c05..791bec03f9 100644
--- a/drivers/crypto/mlx5/mlx5_crypto.c
+++ b/drivers/crypto/mlx5/mlx5_crypto.c
@@ -4,6 +4,7 @@
#include <rte_malloc.h>
#include <rte_mempool.h>
+#include <rte_eal_paging.h>
#include <rte_errno.h>
#include <rte_log.h>
#include <rte_bus_pci.h>
@@ -33,7 +34,7 @@
TAILQ_HEAD(mlx5_crypto_privs, mlx5_crypto_priv) mlx5_crypto_priv_list =
TAILQ_HEAD_INITIALIZER(mlx5_crypto_priv_list);
-static pthread_mutex_t priv_list_lock = PTHREAD_MUTEX_INITIALIZER;
+static pthread_mutex_t priv_list_lock;
int mlx5_crypto_logtype;
@@ -688,7 +689,7 @@ mlx5_crypto_queue_pair_setup(struct rte_cryptodev *dev, uint16_t qp_id,
attr.pd = priv->cdev->pdn;
attr.uar_index = mlx5_os_get_devx_uar_page_id(priv->uar);
attr.cqn = qp->cq_obj.cq->id;
- attr.log_page_size = rte_log2_u32(sysconf(_SC_PAGESIZE));
+ attr.log_page_size = rte_log2_u32(rte_mem_page_size());
attr.rq_size = 0;
attr.sq_size = RTE_BIT32(log_nb_desc);
attr.dbr_umem_valid = 1;
@@ -1014,6 +1015,7 @@ static struct mlx5_class_driver mlx5_crypto_driver = {
RTE_INIT(rte_mlx5_crypto_init)
{
+ pthread_mutex_init(&priv_list_lock, NULL);
mlx5_common_init();
if (mlx5_glue != NULL)
mlx5_class_driver_register(&mlx5_crypto_driver);
--
2.16.1.windows.4
^ permalink raw reply [flat|nested] 8+ messages in thread
* [dpdk-dev] [PATCH 3/5] crypto/mlx5: use OS agnostic functions for UMEM operations
2021-10-12 15:53 [dpdk-dev] [PATCH 0/5] Support MLX5 crypto driver on Windows Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 1/5] common/mlx5: add DV enums to Windows defs file Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 2/5] crypto/mlx5: replace UNIX functions with EAL functions Tal Shnaiderman
@ 2021-10-12 15:53 ` Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 4/5] crypto/mlx5: fix size of UMR WQE Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 5/5] crypto/mlx5: support on Windows Tal Shnaiderman
4 siblings, 0 replies; 8+ messages in thread
From: Tal Shnaiderman @ 2021-10-12 15:53 UTC (permalink / raw)
To: dev
Cc: thomas, matan, rasland, asafp, gakhil, declan.doherty,
viacheslavo, eilong
use the functions mlx5_os_umem_reg, mlx5_os_umem_dereg
mlx5_os_get_umem_id instead of the glue functions to support
UMEM operations on all OSs.
Signed-off-by: Tal Shnaiderman <talshn@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
drivers/crypto/mlx5/mlx5_crypto.c | 8 ++++----
drivers/crypto/mlx5/mlx5_crypto.h | 2 +-
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/crypto/mlx5/mlx5_crypto.c b/drivers/crypto/mlx5/mlx5_crypto.c
index 791bec03f9..11cbc78586 100644
--- a/drivers/crypto/mlx5/mlx5_crypto.c
+++ b/drivers/crypto/mlx5/mlx5_crypto.c
@@ -272,7 +272,7 @@ mlx5_crypto_qp_release(struct mlx5_crypto_qp *qp)
if (qp->qp_obj != NULL)
claim_zero(mlx5_devx_cmd_destroy(qp->qp_obj));
if (qp->umem_obj != NULL)
- claim_zero(mlx5_glue->devx_umem_dereg(qp->umem_obj));
+ claim_zero(mlx5_os_umem_dereg(qp->umem_obj));
if (qp->umem_buf != NULL)
rte_free(qp->umem_buf);
mlx5_mr_btree_free(&qp->mr_ctrl.cache_bh);
@@ -671,7 +671,7 @@ mlx5_crypto_queue_pair_setup(struct rte_cryptodev *dev, uint16_t qp_id,
rte_errno = ENOMEM;
goto error;
}
- qp->umem_obj = mlx5_glue->devx_umem_reg(priv->cdev->ctx,
+ qp->umem_obj = mlx5_os_umem_reg(priv->cdev->ctx,
(void *)(uintptr_t)qp->umem_buf,
umem_size,
IBV_ACCESS_LOCAL_WRITE);
@@ -693,9 +693,9 @@ mlx5_crypto_queue_pair_setup(struct rte_cryptodev *dev, uint16_t qp_id,
attr.rq_size = 0;
attr.sq_size = RTE_BIT32(log_nb_desc);
attr.dbr_umem_valid = 1;
- attr.wq_umem_id = qp->umem_obj->umem_id;
+ attr.wq_umem_id = mlx5_os_get_umem_id(qp->umem_obj);
attr.wq_umem_offset = 0;
- attr.dbr_umem_id = qp->umem_obj->umem_id;
+ attr.dbr_umem_id = mlx5_os_get_umem_id(qp->umem_obj);
attr.ts_format =
mlx5_ts_format_conv(priv->cdev->config.hca_attr.qp_ts_format);
attr.dbr_address = RTE_BIT64(log_nb_desc) * priv->wqe_set_size;
diff --git a/drivers/crypto/mlx5/mlx5_crypto.h b/drivers/crypto/mlx5/mlx5_crypto.h
index 09acc85a56..ef0f383b52 100644
--- a/drivers/crypto/mlx5/mlx5_crypto.h
+++ b/drivers/crypto/mlx5/mlx5_crypto.h
@@ -42,7 +42,7 @@ struct mlx5_crypto_qp {
struct mlx5_devx_cq cq_obj;
struct mlx5_devx_obj *qp_obj;
struct rte_cryptodev_stats stats;
- struct mlx5dv_devx_umem *umem_obj;
+ void *umem_obj;
void *umem_buf;
volatile uint32_t *db_rec;
struct rte_crypto_op **ops;
--
2.16.1.windows.4
^ permalink raw reply [flat|nested] 8+ messages in thread
* [dpdk-dev] [PATCH 4/5] crypto/mlx5: fix size of UMR WQE
2021-10-12 15:53 [dpdk-dev] [PATCH 0/5] Support MLX5 crypto driver on Windows Tal Shnaiderman
` (2 preceding siblings ...)
2021-10-12 15:53 ` [dpdk-dev] [PATCH 3/5] crypto/mlx5: use OS agnostic functions for UMEM operations Tal Shnaiderman
@ 2021-10-12 15:53 ` Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 5/5] crypto/mlx5: support on Windows Tal Shnaiderman
4 siblings, 0 replies; 8+ messages in thread
From: Tal Shnaiderman @ 2021-10-12 15:53 UTC (permalink / raw)
To: dev
Cc: thomas, matan, rasland, asafp, gakhil, declan.doherty,
viacheslavo, eilong, stable
The size of the UMR WQE allocated object is decided by a sizof
operation on the struct, however since the struct contains
a union of flexible array members this sizeof results can differ
between compilers.
GCC for example treats the union as 0 sized, MSVC adds a padding
of 16Bits.
To resolve the ambiguity the allocation size will be calculated
by the sizes of the members excluding the flexible union.
Fixes: a1978aa23bf4 ("crypto/mlx5: add maximum segments configuration")
Cc: stable@dpdk.org
Signed-off-by: Tal Shnaiderman <talshn@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
drivers/crypto/mlx5/mlx5_crypto.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/crypto/mlx5/mlx5_crypto.c b/drivers/crypto/mlx5/mlx5_crypto.c
index 11cbc78586..7192fa661e 100644
--- a/drivers/crypto/mlx5/mlx5_crypto.c
+++ b/drivers/crypto/mlx5/mlx5_crypto.c
@@ -959,7 +959,9 @@ mlx5_crypto_dev_probe(struct mlx5_common_device *cdev)
priv->keytag = rte_cpu_to_be_64(devarg_prms.keytag);
priv->max_segs_num = devarg_prms.max_segs_num;
priv->umr_wqe_size = sizeof(struct mlx5_wqe_umr_bsf_seg) +
- sizeof(struct mlx5_umr_wqe) +
+ sizeof(struct mlx5_wqe_cseg) +
+ sizeof(struct mlx5_wqe_umr_cseg) +
+ sizeof(struct mlx5_wqe_mkey_cseg) +
RTE_ALIGN(priv->max_segs_num, 4) *
sizeof(struct mlx5_wqe_dseg);
rdmw_wqe_size = sizeof(struct mlx5_rdma_write_wqe) +
--
2.16.1.windows.4
^ permalink raw reply [flat|nested] 8+ messages in thread
* [dpdk-dev] [PATCH 5/5] crypto/mlx5: support on Windows
2021-10-12 15:53 [dpdk-dev] [PATCH 0/5] Support MLX5 crypto driver on Windows Tal Shnaiderman
` (3 preceding siblings ...)
2021-10-12 15:53 ` [dpdk-dev] [PATCH 4/5] crypto/mlx5: fix size of UMR WQE Tal Shnaiderman
@ 2021-10-12 15:53 ` Tal Shnaiderman
2021-10-16 15:05 ` [dpdk-dev] [EXT] " Akhil Goyal
4 siblings, 1 reply; 8+ messages in thread
From: Tal Shnaiderman @ 2021-10-12 15:53 UTC (permalink / raw)
To: dev
Cc: thomas, matan, rasland, asafp, gakhil, declan.doherty,
viacheslavo, eilong
Add support for mlx5 crypto pmd on Windows OS.
Add changes to release note and pmd guide.
Signed-off-by: Tal Shnaiderman <talshn@nvidia.com>
---
doc/guides/cryptodevs/mlx5.rst | 15 ++++++++++++---
doc/guides/rel_notes/release_21_11.rst | 1 +
drivers/common/mlx5/version.map | 2 +-
drivers/common/mlx5/windows/mlx5_common_os.c | 2 +-
drivers/crypto/aesni_gcm/meson.build | 6 ++++++
drivers/crypto/aesni_mb/meson.build | 6 ++++++
drivers/crypto/armv8/meson.build | 6 ++++++
drivers/crypto/bcmfs/meson.build | 6 ++++++
drivers/crypto/ccp/meson.build | 1 +
drivers/crypto/kasumi/meson.build | 6 ++++++
drivers/crypto/meson.build | 3 ---
drivers/crypto/mlx5/meson.build | 4 ++--
drivers/crypto/mvsam/meson.build | 6 ++++++
drivers/crypto/null/meson.build | 6 ++++++
drivers/crypto/octeontx/meson.build | 6 ++++++
drivers/crypto/openssl/meson.build | 6 ++++++
drivers/crypto/qat/meson.build | 6 ++++++
drivers/crypto/scheduler/meson.build | 6 ++++++
drivers/crypto/snow3g/meson.build | 6 ++++++
drivers/crypto/virtio/meson.build | 6 ++++++
drivers/crypto/zuc/meson.build | 6 ++++++
21 files changed, 102 insertions(+), 10 deletions(-)
diff --git a/doc/guides/cryptodevs/mlx5.rst b/doc/guides/cryptodevs/mlx5.rst
index 68bfdf3a83..7338c0c493 100644
--- a/doc/guides/cryptodevs/mlx5.rst
+++ b/doc/guides/cryptodevs/mlx5.rst
@@ -39,12 +39,12 @@ or to access the hardware components directly.
There are different levels of objects and bypassing abilities.
To get the best performances:
-- Verbs is a complete high-level generic API.
-- Direct Verbs is a device-specific API.
+- Verbs is a complete high-level generic API (Linux only).
+- Direct Verbs is a device-specific API (Linux only).
- DevX allows to access firmware objects.
Enabling ``librte_crypto_mlx5`` causes DPDK applications
-to be linked against libibverbs.
+to be linked against libibverbs on Linux OS.
In order to move the device to crypto operational mode, credential and KEK
(Key Encrypting Key) should be set as the first step.
@@ -155,8 +155,17 @@ Limitations
Prerequisites
-------------
+Linux Prerequisites
+~~~~~~~~~~~~~~~~~~~
+
- Mellanox OFED version: **5.3**
see :doc:`../../nics/mlx5` guide for more Mellanox OFED details.
- Compilation can be done also with rdma-core v15+.
see :doc:`../../nics/mlx5` guide for more rdma-core details.
+
+Windows Prerequisites
+~~~~~~~~~~~~~~~~~~~~~
+
+- Mellanox WINOF-2 version: **2.60** or higher.
+ see :doc:`../../nics/mlx5` guide for more Mellanox WINOF-2 details.
diff --git a/doc/guides/rel_notes/release_21_11.rst b/doc/guides/rel_notes/release_21_11.rst
index 84278898b9..17a49c20ef 100644
--- a/doc/guides/rel_notes/release_21_11.rst
+++ b/doc/guides/rel_notes/release_21_11.rst
@@ -135,6 +135,7 @@ New Features
Updated the Mellanox mlx5 driver with new features and improvements, including:
* Added implicit mempool registration to avoid data path hiccups (opt-out).
+ * Added support for mlx5 crypto PMD on Windows operating system.
Removed Items
diff --git a/drivers/common/mlx5/version.map b/drivers/common/mlx5/version.map
index 807043f22c..a30e0f9d12 100644
--- a/drivers/common/mlx5/version.map
+++ b/drivers/common/mlx5/version.map
@@ -16,7 +16,7 @@ INTERNAL {
mlx5_dev_mempool_unregister;
mlx5_dev_mempool_subscribe;
- mlx5_devx_alloc_uar; # WINDOWS_NO_EXPORT
+ mlx5_devx_alloc_uar;
mlx5_devx_cmd_alloc_pd;
mlx5_devx_cmd_create_conn_track_offload_obj;
diff --git a/drivers/common/mlx5/windows/mlx5_common_os.c b/drivers/common/mlx5/windows/mlx5_common_os.c
index 44e8ebec2b..ea478d7395 100644
--- a/drivers/common/mlx5/windows/mlx5_common_os.c
+++ b/drivers/common/mlx5/windows/mlx5_common_os.c
@@ -202,7 +202,7 @@ mlx5_os_open_device(struct mlx5_common_device *cdev, uint32_t classes)
struct mlx5_context *mlx5_ctx = NULL;
int n;
- if (classes != MLX5_CLASS_ETH) {
+ if (classes != MLX5_CLASS_ETH && classes != MLX5_CLASS_CRYPTO) {
DRV_LOG(ERR,
"The chosen classes are not supported on Windows.");
rte_errno = ENOTSUP;
diff --git a/drivers/crypto/aesni_gcm/meson.build b/drivers/crypto/aesni_gcm/meson.build
index 0fcac2a8eb..7d0140ff22 100644
--- a/drivers/crypto/aesni_gcm/meson.build
+++ b/drivers/crypto/aesni_gcm/meson.build
@@ -1,6 +1,12 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2018 Intel Corporation
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
IMB_required_ver = '0.52.0'
lib = cc.find_library('IPSec_MB', required: false)
if not lib.found()
diff --git a/drivers/crypto/aesni_mb/meson.build b/drivers/crypto/aesni_mb/meson.build
index ed6b9f53e4..b7512383c3 100644
--- a/drivers/crypto/aesni_mb/meson.build
+++ b/drivers/crypto/aesni_mb/meson.build
@@ -1,6 +1,12 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2018 Intel Corporation
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
IMB_required_ver = '0.52.0'
lib = cc.find_library('IPSec_MB', required: false)
if not lib.found()
diff --git a/drivers/crypto/armv8/meson.build b/drivers/crypto/armv8/meson.build
index 40a4dbb7bb..5effba8bbc 100644
--- a/drivers/crypto/armv8/meson.build
+++ b/drivers/crypto/armv8/meson.build
@@ -1,6 +1,12 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2019 Arm Limited
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
dep = dependency('libAArch64crypto', required: false, method: 'pkg-config')
if not dep.found()
build = false
diff --git a/drivers/crypto/bcmfs/meson.build b/drivers/crypto/bcmfs/meson.build
index d67e78d51b..5842f83a3b 100644
--- a/drivers/crypto/bcmfs/meson.build
+++ b/drivers/crypto/bcmfs/meson.build
@@ -3,6 +3,12 @@
# All rights reserved.
#
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
deps += ['eal', 'bus_vdev']
sources = files(
'bcmfs_logs.c',
diff --git a/drivers/crypto/ccp/meson.build b/drivers/crypto/ccp/meson.build
index 0f82b9b90b..a4f3406009 100644
--- a/drivers/crypto/ccp/meson.build
+++ b/drivers/crypto/ccp/meson.build
@@ -4,6 +4,7 @@
if not is_linux
build = false
reason = 'only supported on Linux'
+ subdir_done()
endif
dep = dependency('libcrypto', required: false, method: 'pkg-config')
if not dep.found()
diff --git a/drivers/crypto/kasumi/meson.build b/drivers/crypto/kasumi/meson.build
index e6e0f08c3d..966b8a5214 100644
--- a/drivers/crypto/kasumi/meson.build
+++ b/drivers/crypto/kasumi/meson.build
@@ -1,6 +1,12 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2018-2020 Intel Corporation
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
IMB_required_ver = '0.53.0'
lib = cc.find_library('IPSec_MB', required: false)
if not lib.found()
diff --git a/drivers/crypto/meson.build b/drivers/crypto/meson.build
index ea239f4c56..c49ec501d4 100644
--- a/drivers/crypto/meson.build
+++ b/drivers/crypto/meson.build
@@ -1,9 +1,6 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
-if is_windows
- subdir_done()
-endif
drivers = [
'aesni_gcm',
diff --git a/drivers/crypto/mlx5/meson.build b/drivers/crypto/mlx5/meson.build
index 1d6e413dd5..9d9c9c00bc 100644
--- a/drivers/crypto/mlx5/meson.build
+++ b/drivers/crypto/mlx5/meson.build
@@ -1,9 +1,9 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright (c) 2021 NVIDIA Corporation & Affiliates
-if not is_linux
+if not (is_linux or is_windows)
build = false
- reason = 'only supported on Linux'
+ reason = 'only supported on Linux and Windows'
subdir_done()
endif
diff --git a/drivers/crypto/mvsam/meson.build b/drivers/crypto/mvsam/meson.build
index fec167bf29..bf3c4323de 100644
--- a/drivers/crypto/mvsam/meson.build
+++ b/drivers/crypto/mvsam/meson.build
@@ -3,6 +3,12 @@
# Copyright(c) 2018 Semihalf.
# All rights reserved.
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
dep = dependency('libmusdk', required: false, method: 'pkg-config')
if not dep.found()
build = false
diff --git a/drivers/crypto/null/meson.build b/drivers/crypto/null/meson.build
index 1f7d644de1..acc16e7d81 100644
--- a/drivers/crypto/null/meson.build
+++ b/drivers/crypto/null/meson.build
@@ -1,5 +1,11 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
deps += 'bus_vdev'
sources = files('null_crypto_pmd.c', 'null_crypto_pmd_ops.c')
diff --git a/drivers/crypto/octeontx/meson.build b/drivers/crypto/octeontx/meson.build
index 244b16230e..48e8e263c1 100644
--- a/drivers/crypto/octeontx/meson.build
+++ b/drivers/crypto/octeontx/meson.build
@@ -1,6 +1,12 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2018 Cavium, Inc
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
deps += ['bus_pci']
deps += ['bus_vdev']
deps += ['common_cpt']
diff --git a/drivers/crypto/openssl/meson.build b/drivers/crypto/openssl/meson.build
index b21fca0be3..cd962da1d6 100644
--- a/drivers/crypto/openssl/meson.build
+++ b/drivers/crypto/openssl/meson.build
@@ -1,6 +1,12 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
dep = dependency('libcrypto', required: false, method: 'pkg-config')
if not dep.found()
build = false
diff --git a/drivers/crypto/qat/meson.build b/drivers/crypto/qat/meson.build
index b3b2d17258..d08a24c7b3 100644
--- a/drivers/crypto/qat/meson.build
+++ b/drivers/crypto/qat/meson.build
@@ -1,6 +1,12 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017-2018 Intel Corporation
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
# this does not build the QAT driver, instead that is done in the compression
# driver which comes later. Here we just add our sources files to the list
build = false
diff --git a/drivers/crypto/scheduler/meson.build b/drivers/crypto/scheduler/meson.build
index d510f49970..cd18efc791 100644
--- a/drivers/crypto/scheduler/meson.build
+++ b/drivers/crypto/scheduler/meson.build
@@ -1,6 +1,12 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2018 Luca Boccassi <bluca@debian.org>
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
deps += ['bus_vdev', 'reorder']
sources = files(
'rte_cryptodev_scheduler.c',
diff --git a/drivers/crypto/snow3g/meson.build b/drivers/crypto/snow3g/meson.build
index 0c087baa2a..ac4d0354ea 100644
--- a/drivers/crypto/snow3g/meson.build
+++ b/drivers/crypto/snow3g/meson.build
@@ -1,6 +1,12 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2019-2020 Intel Corporation
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
IMB_required_ver = '0.53.0'
lib = cc.find_library('IPSec_MB', required: false)
if not lib.found()
diff --git a/drivers/crypto/virtio/meson.build b/drivers/crypto/virtio/meson.build
index 1b6d77f66f..45533c9b89 100644
--- a/drivers/crypto/virtio/meson.build
+++ b/drivers/crypto/virtio/meson.build
@@ -1,6 +1,12 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2018 HUAWEI TECHNOLOGIES CO., LTD.
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
includes += include_directories('../../../lib/vhost')
deps += 'bus_pci'
sources = files(
diff --git a/drivers/crypto/zuc/meson.build b/drivers/crypto/zuc/meson.build
index a5f77a22d8..0a29885610 100644
--- a/drivers/crypto/zuc/meson.build
+++ b/drivers/crypto/zuc/meson.build
@@ -1,6 +1,12 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2018-2020 Intel Corporation
+if is_windows
+ build = false
+ reason = 'not supported on Windows'
+ subdir_done()
+endif
+
IMB_required_ver = '0.53.0'
lib = cc.find_library('IPSec_MB', required: false)
if not lib.found()
--
2.16.1.windows.4
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [dpdk-dev] [EXT] [PATCH 5/5] crypto/mlx5: support on Windows
2021-10-12 15:53 ` [dpdk-dev] [PATCH 5/5] crypto/mlx5: support on Windows Tal Shnaiderman
@ 2021-10-16 15:05 ` Akhil Goyal
2021-10-17 8:15 ` Tal Shnaiderman
0 siblings, 1 reply; 8+ messages in thread
From: Akhil Goyal @ 2021-10-16 15:05 UTC (permalink / raw)
To: Tal Shnaiderman, dev
Cc: thomas, matan, rasland, asafp, declan.doherty, viacheslavo, eilong
> Add support for mlx5 crypto pmd on Windows OS.
> Add changes to release note and pmd guide.
>
> Signed-off-by: Tal Shnaiderman <talshn@nvidia.com>
> ---
> doc/guides/cryptodevs/mlx5.rst | 15 ++++++++++++---
> doc/guides/rel_notes/release_21_11.rst | 1 +
> drivers/common/mlx5/version.map | 2 +-
> drivers/common/mlx5/windows/mlx5_common_os.c | 2 +-
> drivers/crypto/aesni_gcm/meson.build | 6 ++++++
> drivers/crypto/aesni_mb/meson.build | 6 ++++++
> drivers/crypto/armv8/meson.build | 6 ++++++
> drivers/crypto/bcmfs/meson.build | 6 ++++++
> drivers/crypto/ccp/meson.build | 1 +
> drivers/crypto/kasumi/meson.build | 6 ++++++
> drivers/crypto/meson.build | 3 ---
> drivers/crypto/mlx5/meson.build | 4 ++--
> drivers/crypto/mvsam/meson.build | 6 ++++++
> drivers/crypto/null/meson.build | 6 ++++++
> drivers/crypto/octeontx/meson.build | 6 ++++++
> drivers/crypto/openssl/meson.build | 6 ++++++
> drivers/crypto/qat/meson.build | 6 ++++++
> drivers/crypto/scheduler/meson.build | 6 ++++++
> drivers/crypto/snow3g/meson.build | 6 ++++++
> drivers/crypto/virtio/meson.build | 6 ++++++
> drivers/crypto/zuc/meson.build | 6 ++++++
> 21 files changed, 102 insertions(+), 10 deletions(-)
>
Please split this patch into two
- one for all drivers meson.build changes and
- one for enabling Windows compilation for mlx5.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [dpdk-dev] [EXT] [PATCH 5/5] crypto/mlx5: support on Windows
2021-10-16 15:05 ` [dpdk-dev] [EXT] " Akhil Goyal
@ 2021-10-17 8:15 ` Tal Shnaiderman
0 siblings, 0 replies; 8+ messages in thread
From: Tal Shnaiderman @ 2021-10-17 8:15 UTC (permalink / raw)
To: Akhil Goyal, dev
Cc: NBU-Contact-Thomas Monjalon, Matan Azrad, Raslan Darawsheh,
Asaf Penso, declan.doherty, Slava Ovsiienko, Eilon Greenstein
> Subject: RE: [EXT] [PATCH 5/5] crypto/mlx5: support on Windows
>
> External email: Use caution opening links or attachments
>
>
> > Add support for mlx5 crypto pmd on Windows OS.
> > Add changes to release note and pmd guide.
> >
> > Signed-off-by: Tal Shnaiderman <talshn@nvidia.com>
> > ---
> > doc/guides/cryptodevs/mlx5.rst | 15 ++++++++++++---
> > doc/guides/rel_notes/release_21_11.rst | 1 +
> > drivers/common/mlx5/version.map | 2 +-
> > drivers/common/mlx5/windows/mlx5_common_os.c | 2 +-
> > drivers/crypto/aesni_gcm/meson.build | 6 ++++++
> > drivers/crypto/aesni_mb/meson.build | 6 ++++++
> > drivers/crypto/armv8/meson.build | 6 ++++++
> > drivers/crypto/bcmfs/meson.build | 6 ++++++
> > drivers/crypto/ccp/meson.build | 1 +
> > drivers/crypto/kasumi/meson.build | 6 ++++++
> > drivers/crypto/meson.build | 3 ---
> > drivers/crypto/mlx5/meson.build | 4 ++--
> > drivers/crypto/mvsam/meson.build | 6 ++++++
> > drivers/crypto/null/meson.build | 6 ++++++
> > drivers/crypto/octeontx/meson.build | 6 ++++++
> > drivers/crypto/openssl/meson.build | 6 ++++++
> > drivers/crypto/qat/meson.build | 6 ++++++
> > drivers/crypto/scheduler/meson.build | 6 ++++++
> > drivers/crypto/snow3g/meson.build | 6 ++++++
> > drivers/crypto/virtio/meson.build | 6 ++++++
> > drivers/crypto/zuc/meson.build | 6 ++++++
> > 21 files changed, 102 insertions(+), 10 deletions(-)
> >
>
> Please split this patch into two
> - one for all drivers meson.build changes and
> - one for enabling Windows compilation for mlx5.
Sure, I'll split and send a v2.
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2021-10-17 8:15 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-12 15:53 [dpdk-dev] [PATCH 0/5] Support MLX5 crypto driver on Windows Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 1/5] common/mlx5: add DV enums to Windows defs file Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 2/5] crypto/mlx5: replace UNIX functions with EAL functions Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 3/5] crypto/mlx5: use OS agnostic functions for UMEM operations Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 4/5] crypto/mlx5: fix size of UMR WQE Tal Shnaiderman
2021-10-12 15:53 ` [dpdk-dev] [PATCH 5/5] crypto/mlx5: support on Windows Tal Shnaiderman
2021-10-16 15:05 ` [dpdk-dev] [EXT] " Akhil Goyal
2021-10-17 8:15 ` Tal Shnaiderman
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).