[RFC] config: customize max memzones configuration

2023-01-30 Thread Ophir Munk
3 Add a function which must be called before rte_eal_init(): void rte_memzone_set_max(int max) {memzone_max = max;} If not called, the default memzone (RTE_MAX_MEMZONE) is used. With this option there is no need to recompile DPDK and it allows using an in-box packaged DPDK. Signed-off-by: Ophir Mu

RE: [PATCH] net/tap: do not include l2 header in gso size when compared with mtu

2022-05-24 Thread Ophir Munk
gsz > max_size rather than the suggested one: tso_segsz > *txq->mtu + mbuf_in->l2_len) Regards, Ophir > -Original Message- > From: Ferruh Yigit > Sent: Saturday, May 21, 2022 1:08 AM > To: Harold Huang ; dev@dpdk.org; > jiayu...@intel.com;

RE: [RFC] config: customize max memzones configuration

2023-02-12 Thread Ophir Munk
Thanks Dmitry and Bruce for your inputs. Option 1 is my favorite. We all agree on Option 1. I will send a patch based on it. Thank you. > -Original Message- > From: Dmitry Kozlyuk > Sent: Monday, 30 January 2023 12:01 > To: Ophir Munk > Cc: dev@dpdk.org; Ophir Mun

[PATCH v1] config: make max memzones definition configurable

2023-02-12 Thread Ophir Munk
- it is set by default to 2560. The hard coded definition of RTE_MAX_MEMZONE is removed. During meson build time the RTE_MAX_MEMZONE can be optionally defined as the value of max_memzones parameter. Signed-off-by: Ophir Munk --- RFC: https://patchwork.dpdk.org/project/dpdk/patch

RE: [PATCH v1] config: make max memzones definition configurable

2023-02-13 Thread Ophir Munk
ion option. > -Original Message- > From: Bruce Richardson > Sent: Monday, 13 February 2023 16:53 > To: NBU-Contact-Thomas Monjalon (EXTERNAL) > Cc: Ophir Munk ; dev@dpdk.org; Matan Azrad > ; Lior Margalit ; Asaf Penso > ; david.march...@redhat.com; > honnappa.nagaraha.

[PATCH V3] lib: set/get max memzone segments

2023-05-03 Thread Ophir Munk
memzone: rte_memzone_max_get(). Signed-off-by: Ophir Munk --- app/test/test_func_reentrancy.c | 2 +- app/test/test_malloc_perf.c | 2 +- app/test/test_memzone.c | 43 - config/rte_config.h | 1 - drivers/net/qede/base

[PATCH v4] lib: set/get max memzone segments

2023-05-24 Thread Ophir Munk
-by: Ophir Munk Acked-by: Morten Brørup --- app/test/test_func_reentrancy.c | 2 +- app/test/test_malloc_perf.c | 2 +- app/test/test_memzone.c | 42 - config/rte_config.h | 1 - drivers/net/qede/base/bcm_osal.c

RE: [PATCH V3] lib: set/get max memzone segments

2023-05-24 Thread Ophir Munk
Hello David, Thank you for your review. I noticed a review by Anatoly Burakov that addresses similar points to yours. In V4 I supply a reply to you both. > -Original Message- > From: David Marchand > Sent: Thursday, 4 May 2023 10:27 > To: Ophir Munk > Cc: dev@dpdk.org; B

RE: [PATCH V3] lib: set/get max memzone segments

2023-05-24 Thread Ophir Munk
Hi Anatoly, Thank you for your review. I noticed a review by David Marchand that addresses similar points to yours. In V4 I supply a reply to you both. > > Commit message could use a little rewording and shortening. Suggested: > > --- > > Currently, RTE_MAX_MEMZONE constant is used to decide h

RE: [PATCH V3] lib: set/get max memzone segments

2023-05-24 Thread Ophir Munk
Hi Morten, > > I retracted my objection to the RFC, but should also have added: > > Acked-by: Morten Brørup Ack.

RE: [PATCH v4] lib: set/get max memzone segments

2023-05-30 Thread Ophir Munk
> -Original Message- > Subject: Re: [PATCH v4] lib: set/get max memzone segments > > On 5/24/2023 11:25 PM, Ophir Munk wrote: > > Currently, the max memzones count constat (RTE_MAX_MEMZONE) is used > to > > decide how many memzones a DPDK application

[PATCH V5] lib: set/get max memzone segments

2023-05-31 Thread Ophir Munk
-by: Ophir Munk Reviewed-by: Thomas Monjalon Reviewed-by: David Marchand Reviewed-by: Anatoly Burakov Acked-by: Morten Brørup Acked-by: Alok Prasad --- app/test/test_func_reentrancy.c | 2 +- app/test/test_malloc_perf.c | 2 +- app/test/test_memzone.c | 42

RE: [PATCH v4] lib: set/get max memzone segments

2023-05-31 Thread Ophir Munk
> > --- a/lib/eal/common/eal_common_memzone.c > > +++ b/lib/eal/common/eal_common_memzone.c > > +#define DEFAULT_MAX_MEMZONE 2560 > > Maybe add "_COUNT" at the end to make clear it is not about the size of a > memzone. > We should add a comment here to explain the meaning of this default: > used u

[PATCH V6] lib: set/get max memzone segments

2023-05-31 Thread Ophir Munk
-by: Ophir Munk Reviewed-by: Thomas Monjalon Reviewed-by: David Marchand Reviewed-by: Anatoly Burakov Acked-by: Morten Brørup Acked-by: Alok Prasad --- app/test/test_func_reentrancy.c | 2 +- app/test/test_malloc_perf.c | 2 +- app/test/test_memzone.c | 42

[RFC] lib: set/get max memzone segments

2023-04-19 Thread Ophir Munk
memzone: rte_memzone_max_get(). Signed-off-by: Ophir Munk --- app/test/test_func_reentrancy.c | 2 +- app/test/test_malloc_perf.c | 2 +- app/test/test_memzone.c | 2 +- config/rte_config.h | 1 - drivers/net/qede/base/bcm_osal.c| 26

RE: [RFC] lib: set/get max memzone segments

2023-04-20 Thread Ophir Munk
zed. > This commit adds an API which must be called before rte_eal_init(): > rte_memzone_max_set(int max). If not called, the default memzone > (RTE_MAX_MEMZONE) is used. There is also an API to query the effective > max memzone: rte_memzone_max_get(). > > Signed-off-by: Ophir M

RE: [EXT] [RFC] lib: set/get max memzone segments

2023-04-24 Thread Ophir Munk
Thank you Devendra Singh Rawat for your valuable comments. > >+int ecore_mz_mapping_alloc(void) > >+{ > >+ecore_mz_mapping = rte_malloc("ecore_mz_map", 0, > >+rte_memzone_max_get() * sizeof(struct rte_memzone *)); > > Second parameter of rte_malloc() should be size and Third param

RE: [RFC] lib: set/get max memzone segments

2023-04-24 Thread Ophir Munk
Thank you Stephen Memminger for you comment. > Subject: Re: [RFC] lib: set/get max memzone segments > > On Wed, 19 Apr 2023 11:36:34 +0300 > Ophir Munk wrote: > > > +int ecore_mz_mapping_alloc(void) > > +{ > > + ecore_mz_mappi

RE: [RFC] lib: set/get max memzone segments

2023-04-25 Thread Ophir Munk
Thank you, Tyler Retzlaff, for your comments. > > --- a/app/test/test_memzone.c > > +++ b/app/test/test_memzone.c > > @@ -871,7 +871,7 @@ test_memzone_bounded(void) static int > > test_memzone_free(void) > > { > > - const struct rte_memzone *mz[RTE_MAX_MEMZONE + 1]; > > + const struct rte_m

RE: [RFC] lib: set/get max memzone segments

2023-04-25 Thread Ophir Munk
Thank you Morten Brorup and Thomas Monjalon for the fruitful discussion. I am sending a V2 version that meets the understandings in the RFC so far. If confirmed I will send PATCH V1.

[RFC V2] lib: set/get max memzone segments

2023-04-25 Thread Ophir Munk
memzone: rte_memzone_max_get(). Signed-off-by: Ophir Munk --- app/test/test_func_reentrancy.c | 2 +- app/test/test_malloc_perf.c | 2 +- app/test/test_memzone.c | 43 - config/rte_config.h | 1 - drivers/net/qede/base

[PATCH V7] lib: set/get max memzone segments

2023-06-05 Thread Ophir Munk
-by: Ophir Munk Reviewed-by: Thomas Monjalon Reviewed-by: David Marchand Reviewed-by: Anatoly Burakov Acked-by: Morten Brørup Acked-by: Alok Prasad --- app/test/test_func_reentrancy.c | 2 +- app/test/test_malloc_perf.c | 2 +- app/test/test_memzone.c | 42

[PATCH V8] lib: set/get max memzone segments

2023-06-05 Thread Ophir Munk
-by: Ophir Munk Acked-by: Morten Brørup Acked-by: Alok Prasad --- V1-V5 updates based on review comments V6 Style erorr fix V7: rebased V8: positioning changelog in the right place app/test/test_func_reentrancy.c | 2 +- app/test/test_malloc_perf.c | 2 +- app/test/test_memzone.c

[dpdk-dev] [PATCH v1] common/mlx5/linux: replace malloc and free in glue

2020-10-27 Thread Ophir Munk
alloc/free replacements. Fixes: 66914d19d135 ("common/mlx5: convert control path memory to unified malloc") Cc: sta...@dpdk.org Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/common/mlx5/linux/mlx5_glue.c | 14 ++ 1 file changed, 6 insertions(+), 8 deletions(-

[dpdk-dev] [PATCH v1 00/72] mlx5 Windows support - part #5

2020-10-27 Thread Ophir Munk
This patch series is part of preparing mlx5 PMD to compile and run under Windows OS. Part #5 v1: initial version Ophir Munk (46): net/mlx5: fix flow sample definitions net/mlx5/linux: extend device attributes getter net/mlx5: remove Linux files from Windows compilation net/mlx5: fix

[dpdk-dev] [PATCH v1 02/72] net/mlx5: fix flow sample definitions

2020-10-27 Thread Ophir Munk
ample action") Fixes: e8a1d23ae9a8 ("net/mlx5: update translate function for mirror") Cc: sta...@dpdk.org Signed-off-by: Ophir Munk --- drivers/net/mlx5/mlx5_flow_dv.c | 37 + 1 file changed, 37 insertions(+) diff --git a/drivers/net/mlx5/mlx5_flo

[dpdk-dev] [PATCH v1 01/72] mlx5: fix relaxed ordering DevX flow

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman The current DevX implementation of the relaxed ordering feature is enabling relaxed ordering usage only if both relaxed ordering read AND write are supported. In that case both relaxed ordering read and write are activated. This commit will optimize the usage of relaxed or

[dpdk-dev] [PATCH v1 04/72] net/mlx5/linux: extend device attributes getter

2020-10-27 Thread Ophir Munk
This commit adds device attributes parameters to be reported by mlx5_os_get_dev_attr(): max_cqe, max_mr, max_pd, max_srq, max_srq_wr Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/net/mlx5/linux/mlx5_os.c | 5 + drivers/net/mlx5/mlx5.h | 5 + 2 files changed, 10

[dpdk-dev] [PATCH v1 05/72] net/mlx5: remove Linux files from Windows compilation

2020-10-27 Thread Ophir Munk
This commit removes Linux files flow_verbs.c and mlx5_rxtx_vec.c from Windows compilation. Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/net/mlx5/meson.build | 16 +++- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/drivers/net/mlx5/meson.build b

[dpdk-dev] [PATCH v1 03/72] net/mlx5: fix folding constant array error

2020-10-27 Thread Ophir Munk
constant macro definition instead of a variable: #define MLX5_RSS_EXP_ELT_N 8 const int *stack[MLX5_RSS_EXP_ELT_N]; Fixes: c7870bfe09dc ("ethdev: move RSS expansion code to mlx5 driver") Signed-off-by: Tal Shnaiderman Signed-off-by: Ophir Munk --- drivers/net/mlx5/mlx5_f

[dpdk-dev] [PATCH v1 06/72] net/mlx5: fix freeing packet pacing

2020-10-27 Thread Ophir Munk
acket pacing context") Cc: sta...@dpdk.org Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/net/mlx5/mlx5_txpp.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/net/mlx5/mlx5_txpp.c b/drivers/net/mlx5/mlx5_txpp.c index 37355fa..3a16f87 100644 --- a/driver

[dpdk-dev] [PATCH v1 08/72] net/mlx5: define mprq functions as static inline

2020-10-27 Thread Ophir Munk
hich was reported as 'unresolved external symbol' error by some Windows linkers. Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/net/mlx5/mlx5_rxq.c | 71 -- drivers/net/mlx5/mlx5_rxtx.h | 73 +++

[dpdk-dev] [PATCH v1 10/72] net/mlx5: move static_assert calls to global scope

2020-10-27 Thread Ophir Munk
global scope in the files where they are used. Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/net/mlx5/mlx5_rxtx.c | 98 ++-- drivers/net/mlx5/mlx5_txpp.c | 5 ++- 2 files changed, 53 insertions(+), 50 deletions(-) diff --git a/drivers/net/mlx5

[dpdk-dev] [PATCH v1 07/72] net/mlx5: replace Linux sleep with rte sleep

2020-10-27 Thread Ophir Munk
Replace Linux API usleep() and nanosleep() with rte_delay_us_sleep(). The replacement occurs in shared files compiled under different operating systems. Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/net/mlx5/mlx5.c | 5 +++-- drivers/net/mlx5/mlx5_trigger.c | 3

[dpdk-dev] [PATCH v1 11/72] net/mlx5: wrap glue alloc/dealloc PD with OS calls

2020-10-27 Thread Ophir Munk
Wrap glue calls alloc_pd() and dealloc_pd() with generic OS calls. In Linux - protection domain allocations are implemented by Verbs glue API while in Windows it is by DevX API. Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/common/mlx5/linux/mlx5_common_os.h | 11

[dpdk-dev] [PATCH v1 09/72] net/mlx5: do not define static_assert in Windows

2020-10-27 Thread Ophir Munk
update the definition condition to be: #if !defined(HAVE_STATIC_ASSERT) && !defined(RTE_EXEC_ENV_WINDOWS) #define static_assert _Static_assert #endif Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/net/mlx5/mlx5_defs.h | 7 +-- 1 file changed, 5 insertions(+), 2

[dpdk-dev] [PATCH v1 15/72] common/mlx5/linux: handle memory allocations with alignment

2020-10-27 Thread Ophir Munk
. Freeing a memory may be handled differently by operating systems. Therefore this commit wraps these APIs with OS specific calls: mlx5_os_malloc(), mlx5_os_free(). Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/common/mlx5/linux/mlx5_common_os.h | 38

[dpdk-dev] [PATCH v1 18/72] common/mlx5: add Windows exports file

2020-10-27 Thread Ophir Munk
between the two operating systems. Signed-off-by: Tal Shnaiderman Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/common/mlx5/rte_common_mlx5_exports.def | 60 + 1 file changed, 60 insertions(+) create mode 100644 drivers/common/mlx5/rte_common_mlx5_exports.def

[dpdk-dev] [PATCH v1 20/72] common/mlx5: add DevX alloc PD command

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Add a new DevX API mlx5_devx_cmd_alloc_pd() that creates a new protection domain (PD). Signed-off-by: Tal Shnaiderman Acked-by: Matan Azrad --- drivers/common/mlx5/mlx5_devx_cmds.c| 35 drivers/common/mlx5/mlx5_devx_cmds.h

[dpdk-dev] [PATCH v1 22/72] mlx5/windows: add mlx5 meson file

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman File drivers/common/mlx5/windows/meson.build is added to enable mlx5 source files compilation under common windows directory. A Devx SDK tool must be installed to export two external H files: mlx5devx.h and mlx5_ifc_devx.h. The installation is based on environment variable D

[dpdk-dev] [PATCH v1 17/72] common/mlx5/linux: wrap event channel APIs with OS calls

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Wrap the API to create/destroy event channel and to subscribe an event with OS calls. In Linux those calls are implemented by glue functions while in Windows they are not supported. Signed-off-by: Tal Shnaiderman --- drivers/common/mlx5/linux/mlx5_common_os.h | 22 +++

[dpdk-dev] [PATCH v1 19/72] common/mlx5: extend DevX query hca attributes command

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Extend DevX API mlx5_devx_cmd_query_hca_attr() to report on max number of available objects including: CQ, QP, PD, SRQ. Signed-off-by: Tal Shnaiderman Acked-by: Matan Azrad --- drivers/common/mlx5/mlx5_devx_cmds.c | 11 +++ drivers/common/mlx5/mlx5_devx_cmds.h |

[dpdk-dev] [PATCH v1 21/72] common/mlx5/windows: add glue functions APIs

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Windows glue functions are added to file mlx5/windows/mlx5_glue.c. The following APIs are supported: get_device_list, free_device_list, open_device, close_device, query_device, query_hca_iseg, devx_obj_create, devx_obj_destroy, devx_obj_query, devx_obj_modify, devx_general_c

[dpdk-dev] [PATCH v1 16/72] common/mlx5/windows: handle memory allocations with alignment

2020-10-27 Thread Ophir Munk
minimal alignment value. In this way when the memory is free - it is always safe to call _aligned_free(). Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/common/mlx5/windows/mlx5_common_os.h | 51 1 file changed, 51 insertions(+) create mode 100644

[dpdk-dev] [PATCH v1 12/72] net/mlx5: wrap glue reg/dereg UMEM with OS calls

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Wrap glue calls for UMEM registration and deregistration with generic OS calls since each OS (Linux or Windows) has a different glue API parameters. Signed-off-by: Tal Shnaiderman Signed-off-by: Ophir Munk --- drivers/common/mlx5/linux/mlx5_common_os.h | 12

[dpdk-dev] [PATCH v1 14/72] common/mlx5: add definition HAVE_INFINIBAND_VERBS_H

2020-10-27 Thread Ophir Munk
compiles with Verbs or not. Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/common/mlx5/linux/meson.build | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/common/mlx5/linux/meson.build b/drivers/common/mlx5/linux/meson.build index 9ef8e18..4da5bde 100644 --- a/drivers/common

[dpdk-dev] [PATCH v1 13/72] net/mlx5: fix adding destroy flow action wrapper

2020-10-27 Thread Ophir Munk
Glue function destroy_flow_action() was wrapped by OS specific operation mlx5_flow_os_destroy_flow_action(). It was skipped in file mlx5.c. Fixes: b293fbf9672b ("net/mlx5: add OS specific flow actions operations") Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/net/mlx5/

[dpdk-dev] [PATCH v1 23/72] mlx5/windows: add initialization routine for external lib

2020-10-27 Thread Ophir Munk
Add function mlx5_glue_constructor() as an initialization routine for run-time dependency on external lib. Currently the routine has an empty body. It is used for compatibility with Linux. Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/common/mlx5/windows/meson.build | 1

[dpdk-dev] [PATCH v1 24/72] mlx5/windows: generate file mlx5_autoconf.h

2020-10-27 Thread Ophir Munk
File mlx5_autoconf.h is generated under Windows to maintain compatibility with the Linux build system. This file is included in Linux/Windows shared source files therefore it is required. Currently the file is created empty. Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/common

[dpdk-dev] [PATCH v1 27/72] common/mlx5/windows: add OS alloc/dealloc pd

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Implement Windows API mlx5_os_alloc_pd() and mlx5_os_dealloc_pd(). They are equivalent to the Linux implementation. Signed-off-by: Tal Shnaiderman Acked-by: Matan Azrad --- drivers/common/mlx5/rte_common_mlx5_exports.def | 3 +- drivers/common/mlx5/windows/mlx5_common_o

[dpdk-dev] [PATCH v1 25/72] common/mlx5/windows: extend PRM match_param_bits struct

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Add reserved size to PRM 'struct mlx5_ifc_fte_match_param_bits' for non Linux OS. Windows drivers require this extension since their expected size should match the actual struct size. Linux drivers do not require this extension and already use calculations based on the shor

[dpdk-dev] [PATCH v1 26/72] common/mlx5/windows: add getter functions

2020-10-27 Thread Ophir Munk
Add file mlx5/windows/mlx5_common_os.h the equivalent of Linux file mlx5/linux/mlx5_common_os.h. It contains getters functions mlx5_os_get_dev_device_name, mlx5_os_get_ctx_device_name, mlx5_os_get_ctx_device_path, mlx5_os_get_umem_id, mlx5_os_get_devx_channel_fd. Signed-off-by: Ophir Munk Acked

[dpdk-dev] [PATCH v1 35/72] net/mlx5: refactor eth dev ops for Windows

2020-10-27 Thread Ophir Munk
There are two types of eth_dev_ops used under Windows: primary and isolate mode. Their function calls initialization is added to the OS specific file mlx5_os.c. Secondary process eth_dev_ops is nullified. Signed-off-by: Ophir Munk --- drivers/net/mlx5/windows/mlx5_os.c | 108

[dpdk-dev] [PATCH v1 30/72] common/mlx5/windows: add OS reg/dereg MR

2020-10-27 Thread Ophir Munk
This commits implements Windows API for MR registration and deregistration. It is based on DevX. Is support the relaxed ordering flow in Windows by checking the capabilities and machine type. Signed-off-by: Ophir Munk Signed-off-by: Tal Shnaiderman Acked-by: Matan Azrad --- drivers/common

[dpdk-dev] [PATCH v1 33/72] net/mlx5/windows: add mlx5_os.c stubs

2020-10-27 Thread Ophir Munk
with NULL pointers. Signed-off-by: Ophir Munk --- drivers/net/mlx5/windows/mlx5_os.c | 178 + 1 file changed, 178 insertions(+) diff --git a/drivers/net/mlx5/windows/mlx5_os.c b/drivers/net/mlx5/windows/mlx5_os.c index e064667..b0cc9f3 100644 --- a/drivers

[dpdk-dev] [PATCH v1 34/72] net/mlx5/windows: implement mlx5 mac addr add

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Get the list of MAC addresses and verify if the input mac parameter already exists. If not - return -ENOTSUP (as Windows does not support adding new MAC addresses). If the MAC address exists (EEXIST) return 0 (the equivalent of Linux implementation of this API). Signed-off-

[dpdk-dev] [PATCH v1 28/72] common/mlx5/windows: add OS umem reg/dereg API

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Implement Windows API mlx5_os_umem_reg() and mlx5_os_umem_dereg(). They are equivalent to the Linux implementation. Signed-off-by: Tal Shnaiderman --- drivers/common/mlx5/rte_common_mlx5_exports.def | 2 + drivers/common/mlx5/windows/mlx5_common_os.c| 60

[dpdk-dev] [PATCH v1 36/72] common/mlx5/windows: add missing DV and IBV definitions

2020-10-27 Thread Ophir Munk
Add missing DV and IBV definition to file mlx5_win_defs.h. The definitions originated from rdma-core library which is not part of Windows. They are referenced in shared files that must compile under Windows such as mlx5_flow_dv.c and mlx5_rxtx.c. Signed-off-by: Ophir Munk --- drivers/common

[dpdk-dev] [PATCH v1 32/72] net/mlx5/windows: implement device attribute getter

2020-10-27 Thread Ophir Munk
;) Signed-off-by: Ophir Munk --- drivers/common/mlx5/mlx5_prm.h | 43 + drivers/net/mlx5/windows/meson.build | 8 drivers/net/mlx5/windows/mlx5_os.c | 75 3 files changed, 126 insertions(+) create mode 100644 drivers/net/ml

[dpdk-dev] [PATCH v1 29/72] net/mlx5: update MR prototypes for DevX

2020-10-27 Thread Ophir Munk
Currently MR operations are Verbs based. This commit updates MR operations prototypes such that DevX MR operations callbacks can be used as well. Rename 'struct mlx5_verbs_ops' as 'struct mlx5_mr_ops' and move it to shared file mlx5.h. Signed-off-by: Ophir Munk A

[dpdk-dev] [PATCH v1 42/72] common/mlx5/windows: add DevX UAR getters

2020-10-27 Thread Ophir Munk
re DV dependencies") Signed-off-by: Ophir Munk --- drivers/common/mlx5/windows/mlx5_common_os.h | 74 1 file changed, 74 insertions(+) diff --git a/drivers/common/mlx5/windows/mlx5_common_os.h b/drivers/common/mlx5/windows/mlx5_common_os.h index ba16641..9ff6bef 100644 ---

[dpdk-dev] [PATCH v1 37/72] mlx5/windows: add mlx5_os header file under net

2020-10-27 Thread Ophir Munk
File drivers/net/mlx5/windows/mlx5_os.h is added. It includes specific Windows definitions such as PCI driver flags link state changes interrupts, link removal interrupts. Signed-off-by: Ophir Munk --- drivers/net/mlx5/windows/mlx5_os.h | 19 +++ 1 file changed, 19 insertions

[dpdk-dev] [PATCH v1 31/72] drivers/common: enable Windows common mlx5 compilation

2020-10-27 Thread Ophir Munk
Prior to this commit meson did not progress beyond directory drivers/common for Windows compilations. This commit enables drivers compilation under this directory. Signed-off-by: Ophir Munk Acked-by: Matan Azrad --- drivers/common/meson.build | 8 +++- 1 file changed, 3 insertions(+), 5

[dpdk-dev] [PATCH v1 39/72] net/mlx5/windows: define epoll API to do nothing

2020-10-27 Thread Ophir Munk
This is a hack commit. Linux epoll mechanism is not implemented in Windows. Therefore define rte_intr_free_epoll_fd API to do nothing. Signed-off-by: Ophir Munk --- drivers/net/mlx5/windows/mlx5_os.h | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/mlx5/windows/mlx5_os.h b

[dpdk-dev] [PATCH v1 40/72] net/mlx5/windows: define errno ETOOMANYREFS

2020-10-27 Thread Ophir Munk
Errno ETOOMANYREFS may not be supported under Windows. In such cases add its definition. Signed-off-by: Ophir Munk --- drivers/net/mlx5/windows/mlx5_os.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/mlx5/windows/mlx5_os.h b/drivers/net/mlx5/windows/mlx5_os.h index dd3515c

[dpdk-dev] [PATCH v1 38/72] net/mlx5/windows: add pthread initializer definition

2020-10-27 Thread Ophir Munk
PTHREAD_MUTEX_INITIALIZER is a Linux macro defined in /usr/include/pthread.h. It is used by mlx5 PMD but it is not included in DPDK Windows pthread implementation. Therefore define it privately in windows/mlx5_os.h file. Signed-off-by: Ophir Munk --- drivers/net/mlx5/windows/mlx5_os.h | 1 + 1

[dpdk-dev] [PATCH v1 45/72] net/mlx5/windows: add stubs for MP requests

2020-10-27 Thread Ophir Munk
Windows supports the primary process with no secondary process control. This commit adds stubs for requests to start/stop the data-path to the secondary process and for requests to start/stop a queue of the primary process. Signed-off-by: Ophir Munk --- drivers/net/mlx5/windows/meson.build

[dpdk-dev] [PATCH v1 44/72] net/mlx5/windows: add memory region callbacks

2020-10-27 Thread Ophir Munk
This commit is the Windows part implementation of (1). (1) commit d5ed8aa9449d ("net/mlx5: add memory region callbacks in per-device cache")' Signed-off-by: Ophir Munk --- drivers/net/mlx5/windows/mlx5_os.c | 17 + 1 file changed, 17 inse

[dpdk-dev] [PATCH v1 41/72] common/mlx5: add rte compatibility header file

2020-10-27 Thread Ophir Munk
Add #include to file mlx5_devx_cmds.h. It is required for Windows to identify the __rte_internal definition. Signed-off-by: Ophir Munk --- drivers/common/mlx5/mlx5_devx_cmds.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/common/mlx5/mlx5_devx_cmds.h b/drivers

[dpdk-dev] [PATCH v1 47/72] net/mlx5/windows: add ethdev stub operations

2020-10-27 Thread Ophir Munk
mlx5_dev_get_flow_ctrl mlx5_dev_set_flow_ctrl mlx5_get_module_info mlx5_get_module_eeprom Signed-off-by: Ophir Munk --- drivers/net/mlx5/windows/mlx5_ethdev_os.c | 199 ++ 1 file changed, 199 insertions(+) diff --git a/drivers/net/mlx5/windows/mlx5_ethdev_os.c b/drivers/net

[dpdk-dev] [PATCH v1 43/72] common/mlx5/windows: wrap event channel APIs with OS calls

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman This commit is the Windows equivalent of the Linux implementation. Windows returns an error ENOTSUP for the APIs to create/destroy event channel or to subscribe an event. Signed-off-by: Tal Shnaiderman Signed-off-by: Ophir Munk --- drivers/common/mlx5/windows

[dpdk-dev] [PATCH v1 48/72] net/mlx5/windows: support link update

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Add support for mlx5_link_update() to get link speed and link state. Other parameters are currently hard-coded. Signed-off-by: Tal Shnaiderman --- drivers/net/mlx5/windows/mlx5_ethdev_os.c | 39 +++ 1 file changed, 39 insertions(+) diff --git

[dpdk-dev] [PATCH v1 64/72] net/mlx5/windows: introduce flow support

2020-10-27 Thread Ophir Munk
supports flow priority 0. Signed-off-by: Ophir Munk Signed-off-by: Dekel Peled --- drivers/common/mlx5/windows/mlx5_win_defs.h | 7 + drivers/net/mlx5/windows/meson.build| 1 + drivers/net/mlx5/windows/mlx5_flow_os.c | 188 ++ drivers/net/mlx5/windows/mlx5_flow_os.h

[dpdk-dev] [PATCH v1 61/72] net/mlx5/linux: add OS default miss flow action

2020-10-27 Thread Ophir Munk
Wrap glue call dr_create_flow_action_default_miss() with an OS API. This commit is a follow up on (1). (1) commit d4d85aa6f13a ("common/mlx5: add default miss action") commit b293fbf9672b ("net/mlx5: add OS specific flow actions operations") Signed-off-by: Ophir Munk --- dr

[dpdk-dev] [PATCH v1 67/72] net/mlx5/windows: create flow rule

2020-10-27 Thread Ophir Munk
-by: Ophir Munk --- drivers/common/mlx5/mlx5_prm.h | 6 + drivers/net/mlx5/windows/mlx5_flow_os.c | 46 ++--- 2 files changed, 42 insertions(+), 10 deletions(-) diff --git a/drivers/common/mlx5/mlx5_prm.h b/drivers/common/mlx5/mlx5_prm.h index 1dfd6bd

[dpdk-dev] [PATCH v1 50/72] net/mlx5/windows: support get mtu

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman This commit implements API mlx5_get_mtu(). It returns the MTU size as saved in the device context since its creation. Signed-off-by: Tal Shnaiderman --- drivers/net/mlx5/windows/mlx5_ethdev_os.c | 27 +++ 1 file changed, 27 insertions(+) diff --gi

[dpdk-dev] [PATCH v1 68/72] net/mlx5: use HAVE_INFINIBAND_VERBS_H in shared code

2020-10-27 Thread Ophir Munk
: -#ifdef HAVE_IBV_FLOW_DV_SUPPORT +#if defined(HAVE_IBV_FLOW_DV_SUPPORT) || !defined(HAVE_INFINIBAND_VERBS_H) Signed-off-by: Ophir Munk --- drivers/net/mlx5/mlx5.c| 2 +- drivers/net/mlx5/mlx5.h| 4 ++-- drivers/net/mlx5/mlx5_devx.c | 8 drivers/net/mlx5

[dpdk-dev] [PATCH v1 53/72] net/mlx5/windws: add VLAN stubs

2020-10-27 Thread Ophir Munk
This commit adds stubs to VLAN VM operations. It is the Windows equivalent implementation of (1). The Linux implementation was based on Netlink APIs which are not supported in Windows. (1) commit 7af10d29a4a0 ("net/mlx5/linux: refactor VLAN") Signed-off-by: Ophir Munk --- driver

[dpdk-dev] [PATCH v1 63/72] drivers/net: enable Windows net/mlx5 compilation

2020-10-27 Thread Ophir Munk
Add mlx5 as the first driver to be compiled under Windows (file drivers/net/meson.build). Signed-off-by: Ophir Munk --- drivers/net/meson.build | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/drivers/net/meson.build b/drivers/net/meson.build index 4e4c2c9..a341962

[dpdk-dev] [PATCH v1 49/72] net/mlx5/windows: support read clock

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman This commit adds a new glue function query_rt_values to support the new API mlx5_read_clock(). Signed-off-by: Tal Shnaiderman --- drivers/common/mlx5/mlx5_prm.h | 1 + drivers/common/mlx5/windows/mlx5_glue.c| 26 ++ drivers/common/

[dpdk-dev] [PATCH v1 71/72] net/mlx5: fix Windows warnings on get_if_name

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Windows warns on missing function prototype get_if_name. To fix it - move the prototype to shared file mlx5.h and add missing definition IF_NAMESIZE to Windows mlx5_os.h file. Fixes: e9c0b96e3526 ("net/mlx5: move Linux ifname function") Cc: sta...@dpdk.org Signed-off-by: T

[dpdk-dev] [PATCH v1 69/72] net/mlx5: fix separating eth_dev_ops per OS

2020-10-27 Thread Ophir Munk
case an OS does not support an API - it can return in its implementation an error ENOTSUP. Fixes: 042f5c94fd3a ("net/mlx5: refactor device operations for Linux") Fixes: b541ecb63618 ("net/mlx5: refactor eth dev ops for Windows") Signed-off-by: Ophir Munk --- drivers/net/

[dpdk-dev] [PATCH v1 46/72] net/mlx5/windows: support get mac

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman This commits implements API mlx5_get_mac(). It returns the MAC address saved in the device context since its creation. Signed-off-by: Tal Shnaiderman --- drivers/net/mlx5/windows/meson.build | 1 + drivers/net/mlx5/windows/mlx5_ethdev_os.c | 43

[dpdk-dev] [PATCH v1 66/72] net/mlx5/windows: create flow action dest TIR object

2020-10-27 Thread Ophir Munk
added to array of actions and will be used later by the flow creation API. Signed-off-by: Ophir Munk --- drivers/common/mlx5/windows/mlx5_win_defs.h | 16 drivers/net/mlx5/windows/mlx5_flow_os.c | 21 ++--- 2 files changed, 30 insertions(+), 7 deletions(-) diff

[dpdk-dev] [PATCH v1 52/72] net/mlx5/windows: support is removed

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman This commit implements mlx5_is_removed() API. A new glue call 'init_shutdown_event' is added to support the new API. Signed-off-by: Tal Shnaiderman --- drivers/common/mlx5/windows/mlx5_glue.c| 21 + drivers/common/mlx5/windows/mlx5_glue.h| 1 +

[dpdk-dev] [PATCH v1 65/72] net/mlx5/windows: create flow matcher object

2020-10-27 Thread Ophir Munk
format and copy the DV translated PRM bits into the matcher struct. This matcher struct will be used later by the flow creation API. Signed-off-by: Ophir Munk --- drivers/common/mlx5/windows/mlx5_win_defs.h | 55 + drivers/net/mlx5/windows/mlx5_flow_os.c | 30

[dpdk-dev] [PATCH v1 70/72] common/mlx5: fix Windows warnings on missing enum

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman This commit replaces included file mlx5_glue.h with file mlx5_prm.h in file mlx5_common_mp.h. The new inclusion defines 'enum ibv_wq_state' which is used in file mlx5_common_mp.h and causes Windows compilation warnings if not declared in advance. Fixes: 9d60f54569fd ("commo

[dpdk-dev] [PATCH v1 56/72] net/mlx5/windows: support open device

2020-10-27 Thread Ophir Munk
This commit implements mlx5_os_open_device() API. It calls glue API open_device() then glue API query_device() to fill in 'struct mlx5_context' with data for later usage. Signed-off-by: Ophir Munk --- drivers/net/mlx5/windows/mlx5_os.c | 43 ++ 1 fi

[dpdk-dev] [PATCH v1 51/72] net/mlx5/windows: support get interface name

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman This commit copies the interface name as saved in the device context since its creation. Signed-off-by: Tal Shnaiderman --- drivers/net/mlx5/windows/mlx5_ethdev_os.c | 28 1 file changed, 28 insertions(+) diff --git a/drivers/net/mlx5/windows

[dpdk-dev] [PATCH v1 60/72] net/mlx5/linux: wrap adjust flow priority with OS calls

2020-10-27 Thread Ophir Munk
mlx5_flow_adjust_priority() is used to adjust priorities according to priorities levels. It is Verbs based and it is called from shared code (mlx5_flow_dv.c). Therefore, wrap it in an OS API. Signed-off-by: Ophir Munk --- drivers/net/mlx5/linux/mlx5_flow_os.h | 20 drivers

[dpdk-dev] [PATCH v1 72/72] mlx5: build pmd only with the clang compiler

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Currently the mlx5 PMD is supported on Windows for clang compiler only, adding restriction in meson.build files until mingw support will be added as well. Signed-off-by: Tal Shnaiderman --- drivers/common/mlx5/meson.build | 4 ++-- drivers/net/mlx5/meson.build| 4 ++--

[dpdk-dev] [PATCH v1 58/72] net/mlx5/windws: spawn eth devices

2020-10-27 Thread Ophir Munk
-off-by: Ophir Munk --- drivers/common/mlx5/windows/mlx5_win_defs.h | 6 + drivers/net/mlx5/windows/mlx5_os.c | 481 +++- 2 files changed, 482 insertions(+), 5 deletions(-) diff --git a/drivers/common/mlx5/windows/mlx5_win_defs.h b/drivers/common/mlx5/windows

[dpdk-dev] [PATCH v1 57/72] net/mlx5/windows: initial probing implementation

2020-10-27 Thread Ophir Munk
each PCI device call mlx5_dev_spawn() to create an eth device (struct rte_ethdev). The implementation of device spawn is in the follow up commit. Finally, the device list is free. Signed-off-by: Tal Shnaiderman Signed-off-by: Ophir Munk --- drivers/net/mlx5/windows/mlx5_os.c | 278

[dpdk-dev] [PATCH v1 54/72] net/mlx5: exclude rte_intr_callback_register call

2020-10-27 Thread Ophir Munk
Exclude call to rte_intr_callback_register under Windows using definition RTE_EXEC_ENV_WINDOWS. Signed-off-by: Ophir Munk --- drivers/net/mlx5/mlx5_txpp.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/mlx5/mlx5_txpp.c b/drivers/net/mlx5/mlx5_txpp.c index c22ddc9..4405054

[dpdk-dev] [PATCH v1 59/72] net/mlx5/windows: support VF PCI address

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Support VF BDF scanning by checking both the BDF and raw BDF provided by DevX. In Linux a PCI address is formatted as: domain, bus, device, function (DBDF). This is right for both a PF and a VF. In Windows a PF also has a DBDF format, but the domain is always 0, while a VF

[dpdk-dev] [PATCH v1 55/72] net/mlx5/windows: support get pdn

2020-10-27 Thread Ophir Munk
From: Tal Shnaiderman Implement OS function call to get pdn. Signed-off-by: Tal Shnaiderman --- drivers/net/mlx5/windows/mlx5_os.c | 21 + 1 file changed, 21 insertions(+) diff --git a/drivers/net/mlx5/windows/mlx5_os.c b/drivers/net/mlx5/windows/mlx5_os.c index e334110..

[dpdk-dev] [PATCH v1 62/72] net/mlx5/linux: fix add OS dest_devx_tir action

2020-10-27 Thread Ophir Munk
Wrap glue call dv_create_flow_action_dest_devx_tir() with an OS API. Fixes: b293fbf9672b ("net/mlx5: add OS specific flow actions operations") Cc: sta...@dpdk.org Signed-off-by: Ophir Munk --- drivers/net/mlx5/linux/mlx5_flow_os.h | 26 ++ drivers/net/mlx5/m

[dpdk-dev] [PATCH v1] regex/mlx5: add out of order scan capability

2020-10-28 Thread Ophir Munk
Add missing out of order scan capability RTE_REGEXDEV_CAPA_QUEUE_PAIR_OOS_F to mlx5 regex PMD. Signed-off-by: Ophir Munk Acked-by: Ori Kam --- Depends-on: patch-81673 ("regexdev: add OOS capability definition") ` Depends-on: patch-81509 ("app/regex: configure qp acco

[dpdk-dev] [PATCH] net/mlx5: allow multi probing

2018-10-03 Thread Ophir Munk
ip an already probed device") https://patches.dpdk.org/project/dpdk/list/?series=1580 Signed-off-by: Ophir Munk --- drivers/net/mlx5/mlx5.c | 22 +- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/drivers/net/mlx5/mlx5.c b/drivers/net/mlx5/mlx5.c ind

[dpdk-dev] [PATCH] net/mlx5: set RSS key len 0 to indicate default RSS

2018-10-03 Thread Ophir Munk
table and length. Signed-off-by: Ophir Munk --- drivers/net/mlx5/mlx5_flow.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c index 3f548a9..18eacf5 100644 --- a/drivers/net/mlx5/mlx5_flow.c +++ b/drivers/net

  1   2   3   4   5   6   >