[PATCH v1] bus/pci: get PCI address from rte_device

2023-05-30 Thread eagostini
From: Elena Agostini In DPDK 22.11 pci bus related structure have been hidden internally so the application doesn't have a direct access to those info anymore. This patch introduces a get function to retrieve a PCI address from an rte_device handler. Signed-off-by: Elena Agostini --- drivers/

[PATCH v3] net: fix return type of IPv4 L4 packet checksum

2023-04-12 Thread eagostini
From: Elena Agostini Function returns 0 or -1 but the return type is uint16_t. Fixes: d178f693bbfe ("net: add UDP/TCP checksum in mbuf segments") Cc: xiaoyun...@intel.com Signed-off-by: Elena Agostini --- V2: added fixline and fixed cc address V3: title changed --- lib/net/rte_ip.h | 2

[PATCH v2] net: fix return type of IPv6 L4 packet checksum

2023-04-06 Thread eagostini
From: Elena Agostini Function returns 0 or -1 but the return type is uint16_t. Fixes: d178f693bbfe ("net: add UDP/TCP checksum in mbuf segments") Cc: xiaoyun...@intel.com Signed-off-by: Elena Agostini --- V2: added fixline and fixed cc address --- --- lib/net/rte_ip.h | 2 +- 1 file chang

[PATCH] net: fix return type of IPv6 L4 packet checksum

2023-04-06 Thread eagostini
From: Elena Agostini Function returns 0 or -1 but the return type is uint16_t. Signed-off-by: Elena Agostini --- lib/net/rte_ip.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/net/rte_ip.h b/lib/net/rte_ip.h index a310e9d498..e7106256aa 100644 --- a/lib/net/rte_ip.h +

[PATCH] gpudev: fix deadlocks when registering callback

2023-01-29 Thread eagostini
Agree with the patch. Thanks!

[PATCH] gpu/cuda: GPU_REGISTERED to distinguish GPU memory CPU mapped

2022-04-29 Thread eagostini
From: Elena Agostini Enable GPU_REGISTERED flag in gpu/cuda driver in the memory list. If a GPU memory address CPU mapped is freed before being unmapped, CUDA driver unmaps it before freeing the memory. Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 77

[PATCH] gpu/cuda: GPU_REGISTERED to distinguish GPU memory CPU mapped

2022-04-29 Thread eagostini
From: Elena Agostini Enable GPU_REGISTERED flag in gpu/cuda driver in the memory list. If a GPU memory address CPU mapped is freed before being unmapped, CUDA driver unmaps it before freeing the memory. Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 78 +---

[PATCH] gpu/cuda: add more NVIDIA GPU devices

2022-04-13 Thread eagostini
From: Elena Agostini Add more NVIDIA GPU devices to the gpu/cuda driver list compatible with GPUDirect RDMA. Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c| 173 +++-- drivers/gpu/cuda/devices.h | 74 2 files changed, 220 inserti

[PATCH] gpu/cuda: add new A30X GPU type code for DPU

2022-04-04 Thread eagostini
From: Elena Agostini A30X GPU code for DPU. Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/gpu/cuda/cuda.c b/drivers/gpu/cuda/cuda.c index 8505d39d64..92097e067e 100644 --- a/drivers/gpu/cuda/cuda.c +++ b/drivers/gpu/c

[PATCH v1] gpu/cuda: set unused gdrcopy functions arguments

2022-03-09 Thread eagostini
From: Elena Agostini Without enabling gdrcopy, dpdk build has warnings about unused gdrcopy functions input parameters. This patch set them to __rte_unused . Fixes: 24c7759 ("gpu/cuda: map GPU memory with GDRCopy") Signed-off-by: Elena Agostini --- drivers/gpu/cuda/gdrcopy.c | 4 ++-- 1 file

[PATCH v2 2/2] gpudev: use page_size in comm_list creation

2022-03-08 Thread eagostini
From: Elena Agostini Memory allocated for CPU mapping the status flag in the communication list should be aligned to the GPU page size. Fixes: 9b8cae4d991e ("gpudev: use CPU mapping in communication list") Signed-off-by: Elena Agostini --- lib/gpudev/gpudev.c | 9 - 1 file changed, 8 i

[PATCH v2 1/2] gpudev: add GPU page_size to info

2022-03-08 Thread eagostini
From: Elena Agostini Page alignment on the GPU can be different from the CPU page alignment. Fixes: 9b8cae4d991e ("gpudev: use CPU mapping in communication list") Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 4 lib/gpudev/rte_gpudev.h | 2 ++ 2 files changed, 6 insertions(+

[PATCH] gpu/cuda: missing slash in libcuda.so path

2022-03-01 Thread eagostini
From: Elena Agostini Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/cuda/cuda.c b/drivers/gpu/cuda/cuda.c index 2f8c4684ce..8505d39d64 100644 --- a/drivers/gpu/cuda/cuda.c +++ b/drivers/gpu/cuda/cuda.c @@

[PATCH v1 1/2] gpudev: add GPU page_size to info

2022-03-01 Thread eagostini
From: Elena Agostini Page alignment on the GPU can be different from the CPU page alignment. Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 4 lib/gpudev/rte_gpudev.h | 2 ++ 2 files changed, 6 insertions(+) diff --git a/drivers/gpu/cuda/cuda.c b/drivers/gpu/cuda/cuda.c inde

[PATCH v1 2/2] gpudev: use page_size in comm_list creation

2022-03-01 Thread eagostini
From: Elena Agostini Memory allocated for CPU mapping the status flag in the communication list should be aligned to the GPU page size. Signed-off-by: Elena Agostini --- lib/gpudev/gpudev.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/lib/gpudev/gpudev.c b/lib/gp

[PATCH v4 2/2] gpu/cuda: CPU map GPU memory with GDRCopy

2022-02-24 Thread eagostini
From: Elena Agostini To enable the gpudev rte_gpu_mem_cpu_map feature to expose GPU memory to the CPU, the GPU CUDA driver library needs the GDRCopy library and driver. If DPDK is built without GDRCopy, the GPU CUDA driver returns error if the is invoked rte_gpu_mem_cpu_map. All the others GPU

[PATCH v4 1/2] doc/gpus: add cuda.ini into features

2022-02-24 Thread eagostini
From: Elena Agostini Signed-off-by: Elena Agostini --- doc/guides/gpus/features/cuda.ini | 12 1 file changed, 12 insertions(+) create mode 100644 doc/guides/gpus/features/cuda.ini diff --git a/doc/guides/gpus/features/cuda.ini b/doc/guides/gpus/features/cuda.ini new file mode 1

[PATCH v3] gpu/cuda: CPU map GPU memory with GDRCopy

2022-02-23 Thread eagostini
From: Elena Agostini To enable the gpudev rte_gpu_mem_cpu_map feature to expose GPU memory to the CPU, the GPU CUDA driver library needs the GDRCopy library and driver. If DPDK is built without GDRCopy, the GPU CUDA driver returns error if the is invoked rte_gpu_mem_cpu_map. All the others GPU

[PATCH v2] gpudev: use CPU map functionality in comm list

2022-02-21 Thread eagostini
From: Elena Agostini rte_gpu_mem_cpu_map() exposes a GPU memory area to the CPU. In gpudev communication list this is useful to store the status flag. A communication list status flag allocated on GPU memory and mapped for CPU visibility can be updated by CPU and polled by a GPU workload. The p

[PATCH v1] gpudev: use CPU map functionality in comm list

2022-02-21 Thread eagostini
From: Elena Agostini rte_gpu_mem_cpu_map() exposes a GPU memory area to the CPU. In gpudev communication list this is useful to store the status flag. A communication list status flag allocated on GPU memory and mapped for CPU visibility can be updated by CPU and polled by a GPU workload. The p

[PATCH] gpudev: improve CPU unmap description

2022-02-21 Thread eagostini
From: Elena Agostini Minor update in rte_gpu_mem_cpu_unmap header documentation. Signed-off-by: Elena Agostini --- lib/gpudev/rte_gpudev.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/gpudev/rte_gpudev.h b/lib/gpudev/rte_gpudev.h index 5cc4eb5828..9802bff2a5 100644 -

[PATCH] app/test-gpudev: use GPU ptr to CPU unmap

2022-02-21 Thread eagostini
From: Elena Agostini Use rte_gpu_mem_cpu_map with the GPU memory pointer. Signed-off-by: Elena Agostini --- app/test-gpudev/main.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/test-gpudev/main.c b/app/test-gpudev/main.c index 417f2d78b7..d4b8b8971d 100644 ---

[PATCH v2] gpu/cuda: CPU map GPU memory with GDRCopy

2022-02-21 Thread eagostini
From: Elena Agostini To enable the gpudev rte_gpu_mem_cpu_map feature to expose GPU memory to the CPU, the GPU CUDA driver library needs the GDRCopy library and driver. If DPDK is built without GDRCopy, the GPU CUDA driver returns error if the is invoked rte_gpu_mem_cpu_map. All the others GPU

[PATCH] gpu/cuda: differentiate V100 32GB GPU IDs

2022-02-09 Thread eagostini
From: Elena Agostini Differentiate between GPU V100 32GB SMX2 device id and V100 32GB PCIe device id. Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/cuda/cuda.c b/drivers/gpu/cuda/cuda.c index 0

[PATCH v5 2/2] app/test-gpudev: test cpu_map/cpu_unmap functions

2022-01-26 Thread eagostini
From: Elena Agostini New test case added to test the gpudev cpu_map/cpu_unmap functions. Signed-off-by: Elena Agostini --- app/test-gpudev/main.c | 63 ++ 1 file changed, 63 insertions(+) diff --git a/app/test-gpudev/main.c b/app/test-gpudev/main.c inde

[PATCH v5 1/2] gpudev: expose GPU memory to CPU

2022-01-26 Thread eagostini
From: Elena Agostini Enable the possibility to expose a GPU memory area and make it accessible from the CPU. GPU memory has to be allocated via rte_gpu_mem_alloc(). This patch allows the gpudev library to map (and unmap), through the GPU driver, a chunk of GPU memory and to return a memory poin

[PATCH v4 2/2] app/test-gpudev: test cpu_map/cpu_unmap functions

2022-01-26 Thread eagostini
From: Elena Agostini New test case added to test the gpudev cpu_map/cpu_unmap functions. Signed-off-by: Elena Agostini --- app/test-gpudev/main.c | 63 ++ 1 file changed, 63 insertions(+) diff --git a/app/test-gpudev/main.c b/app/test-gpudev/main.c inde

[PATCH v4 1/2] gpudev: expose GPU memory to CPU

2022-01-26 Thread eagostini
From: Elena Agostini Enable the possibility to expose a GPU memory area and make it accessible from the CPU. GPU memory has to be allocated via rte_gpu_mem_alloc(). This patch allows the gpudev library to map (and unmap), through the GPU driver, a chunk of GPU memory and to return a memory poin

[PATCH v1] gpu/cuda: add NVIDIA GPU A100 identifier for DPU

2022-01-19 Thread eagostini
From: Elena Agostini Adding a new NVIDIA GPU identifier to let driver recognize the A100 on a DPU card. Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/gpu/cuda/cuda.c b/drivers/gpu/cuda/cuda.c index 882df08e56..c295e7c

[PATCH v1 1/1] gpu/cuda: expose GPU memory with GDRCopy

2022-01-11 Thread eagostini
From: Elena Agostini GPU CUDA implementation of the new gpudev functions to expose GPU memory to the CPU. Today GDRCopy library is required to pin and DMA map the GPU memory through the BAR1 of the GPU and expose it to the CPU. Goal here is to hide technical details GDRCopy library and expose t

[PATCH v1 0/1] gpu/cuda: expose GPU memory with GDRCopy

2022-01-11 Thread eagostini
From: Elena Agostini GPU CUDA implementation of the new gpudev functions to expose GPU memory to the CPU. Today GDRCopy library is required to pin and DMA map the GPU memory through the BAR1 of the GPU and expose it to the CPU. Goal here is to hide technical details GDRCopy library and expose t

[PATCH v2 3/3] gpu/cuda: mem alloc aligned memory

2022-01-07 Thread eagostini
From: Elena Agostini Implement aligned GPU memory allocation in GPU CUDA driver. Changelog: - cuda_mem_alloc parameters order Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 21 - 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/cuda/c

[PATCH v2 2/3] app/test-gpudev: test aligned memory allocation

2022-01-07 Thread eagostini
From: Elena Agostini Update gpudev app to test GPU memory aligned allocation. Signed-off-by: Elena Agostini --- app/test-gpudev/main.c | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/app/test-gpudev/main.c b/app/test-gpudev/main.c index 5c1aa3d52f..f36f46cbca

[PATCH v2 1/3] gpudev: mem alloc aligned memory

2022-01-07 Thread eagostini
From: Elena Agostini Similarly to rte_malloc, rte_gpu_mem_alloc accept as input the memory alignment size. GPU driver should return GPU memory address aligned with the input value. Changelog: - rte_gpu_mem_alloc parameters order Signed-off-by: Elena Agostini --- lib/gpudev/gpudev.c|

[PATCH v3] gpudev: expose GPU memory

2022-01-07 Thread eagostini
From: Elena Agostini Enable the possibility to expose a GPU memory area and make it accessible from the CPU. GPU memory has to be allocated via rte_gpu_mem_alloc(). This patch allows the gpudev library to expose (and unexpose), through the GPU driver, a chunk of GPU memory and to return a memor

[PATCH v2] gpudev: pin GPU memory

2022-01-03 Thread eagostini
From: Elena Agostini Enable the possibility to make a GPU memory area accessible from the CPU. GPU memory has to be allocated via rte_gpu_mem_alloc(). This patch allows the gpudev library to pin, through the GPU driver, a chunk of GPU memory and to return a memory pointer usable by the CPU to a

[PATCH v2] gpudev: pin GPU memory

2022-01-03 Thread eagostini
From: Elena Agostini Enable the possibility to make a GPU memory area accessible from the CPU. GPU memory has to be allocated via rte_gpu_mem_alloc(). This patch allows the gpudev library to pin, through the GPU driver, a chunk of GPU memory and to return a memory pointer usable by the CPU to a

[PATCH v1] gpudev: pin GPU memory

2022-01-03 Thread eagostini
From: Elena Agostini Enable the possibility to make a GPU memory area accessible from the CPU. GPU memory has to be allocated via rte_gpu_mem_alloc(). This patch allows the gpudev library to pin, through the GPU driver, a chunk of GPU memory and to return a memory pointer usable by the CPU to a

[PATCH v1 3/3] gpu/cuda: mem alloc aligned memory

2022-01-03 Thread eagostini
From: Elena Agostini Implement aligned GPU memory allocation in GPU CUDA driver. Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 21 - 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/cuda/cuda.c b/drivers/gpu/cuda/cuda.c index 882df08e

[PATCH v1 2/3] app/test-gpudev: test aligned memory allocation

2022-01-03 Thread eagostini
From: Elena Agostini Update gpudev app to test GPU memory aligned allocation. Signed-off-by: Elena Agostini --- app/test-gpudev/main.c | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/app/test-gpudev/main.c b/app/test-gpudev/main.c index 5c1aa3d52f..f36f46cbca

[PATCH v1 1/3] gpudev: mem alloc aligned memory

2022-01-03 Thread eagostini
From: Elena Agostini Similarly to rte_malloc, rte_gpu_mem_alloc accept as input the memory alignment size. GPU driver should return GPU memory address aligned with the input value. Signed-off-by: Elena Agostini --- lib/gpudev/gpudev.c| 10 -- lib/gpudev/gpudev_driver.h | 2 +-

[PATCH v1 0/3] GPU memory aligned

2022-01-03 Thread eagostini
From: Elena Agostini Applications may need to allocate GPU memory buffers with memory address aligned to some value (e.g. page size). Similarly to the rte_malloc function, aligned size can be provided as input to rte_gpu_mem_alloc. This set of patches implements this functionality in the gpudev

[PATCH v1] gpu/cuda: fix memory list cleanup

2021-12-21 Thread eagostini
From: Elena Agostini Memory list cleanup (called by cuda_mem_free) was not properly set the new head of the list when deleting an entry. Fixes: 1306a73b1958 ("gpu/cuda: introduce CUDA driver") Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 6 -- 1 file changed, 4 insertions(+

[PATCH v1] net/mlx5: adding extern C to rte_pmd_mlx5.h

2021-12-16 Thread eagostini
From: Elena Agostini The support for linking rte_pmd_mlx5.h functions with C++ applications was missing. Signed-off-by: Elena Agostini --- drivers/net/mlx5/rte_pmd_mlx5.h | 8 1 file changed, 8 insertions(+) diff --git a/drivers/net/mlx5/rte_pmd_mlx5.h b/drivers/net/mlx5/rte_pmd_mlx5

[PATCH v3] app/test-gpudev: remove all memory leaks

2021-11-25 Thread eagostini
From: Elena Agostini Remove all memory leaks in case of errors in test-gpudev application. Fixes: e818c4e2bf50 ("gpudev: add memory API") Fixes: c7ebd65c1372 ("gpudev: add communication list") Signed-off-by: Elena Agostini --- app/test-gpudev/main.c | 17 - 1 file changed, 16

[PATCH v1] gpudev: remove unnecessary rte_gpu_wmb

2021-11-25 Thread eagostini
From: Elena Agostini Remove unnecessary rte_gpu_wmb from rte_gpu_comm_populate_list_pkts. It causes a performance degradation in case of NVIDIA GPU V100. This change doesn't affect any functionality as the status resides in CPU registered memory. Fixes: c7ebd65c1372 ("gpudev: add communication

[PATCH v2] gpu/cuda: set rte_errno

2021-11-24 Thread eagostini
From: Elena Agostini Set correct rte_errno variable in gpu/cuda and return -rte_errno in case of error. rte_errno values are compliant with the gpudev library documentation. Fixes: 1306a73b1958 ("gpu/cuda: introduce CUDA driver") Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 18

[PATCH v7] gpudev: manage NULL pointer

2021-11-22 Thread eagostini
From: Elena Agostini gpudev free and unregister functions return gracefully if input pointer is NULL because API doc was indicating NULL as a no-op accepted value. cuda driver checks are removed because redundant with the checks added in gpudev library. Fixes: e818c4e2bf50 ("gpudev: add memory

[PATCH v6] gpudev: manage NULL pointer

2021-11-22 Thread eagostini
From: Elena Agostini gpudev free and unregister functions return gracefully if input pointer is NULL because API doc was indicating NULL as a no-op accepted value. cuda driver checks are removed because redundant with the checks added in gpudev library. Fixes: e818c4e2bf50 ("gpudev: add memory

[PATCH v5] gpudev: manage NULL pointer

2021-11-22 Thread eagostini
From: Elena Agostini gpudev free and unregister functions return gracefully if input pointer is NULL because API doc was indicating NULL as a no-op accepted value. cuda driver checks are removed because redundant with the checks added in gpudev library. Fixes: e818c4e2bf50 ("gpudev: add memory

[PATCH v4] gpudev: manage NULL pointer

2021-11-22 Thread eagostini
From: Elena Agostini gpudev free and unregister functions return gracefully if input pointer is NULL because API doc was indicating NULL as a no-op accepted value. cuda driver checks are removed because redundant with the checks added in gpudev library. Fixes: e818c4e2bf50 ("gpudev: add memory

[PATCH v3] gpudev: manage NULL pointer

2021-11-22 Thread eagostini
From: Elena Agostini gpudev free and unregister functions return gracefully if input pointer is NULL Fixes: 818a067baf90 ("gpudev: manage NULL pointer") Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 6 -- lib/gpudev/gpudev.c | 6 ++ 2 files changed, 6 insertions(+),

[PATCH v1] gpu/cuda: properly set rte_errno

2021-11-18 Thread eagostini
From: Elena Agostini Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 229 +++- 1 file changed, 153 insertions(+), 76 deletions(-) diff --git a/drivers/gpu/cuda/cuda.c b/drivers/gpu/cuda/cuda.c index 24ae630d04..9991f9b9f1 100644 --- a/drivers/gpu

[PATCH v2] gpudev: free and unregister return gracefully if input pointer is NULL

2021-11-18 Thread eagostini
From: Elena Agostini Signed-off-by: Elena Agostini --- drivers/gpu/cuda/cuda.c | 4 ++-- lib/gpudev/gpudev.c | 6 ++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/cuda/cuda.c b/drivers/gpu/cuda/cuda.c index 24ae630d04..f68e2b20b9 100644 --- a/drivers/gpu/cud

[PATCH v1] gpudev: return EINVAL if invalid input pointer for free and unregister

2021-11-18 Thread eagostini
From: Elena Agostini Signed-off-by: Elena Agostini --- lib/gpudev/gpudev.c | 10 ++ lib/gpudev/rte_gpudev.h | 2 ++ 2 files changed, 12 insertions(+) diff --git a/lib/gpudev/gpudev.c b/lib/gpudev/gpudev.c index 2b174d8bd5..97575ed979 100644 --- a/lib/gpudev/gpudev.c +++ b/lib/gpud

[PATCH v2 1/1] app/test-gpudev: introduce ethdev to rx/tx packets using GPU memory

2021-11-18 Thread eagostini
From: Elena Agostini This patch introduces ethdev in test-gpudev app to provide: - an example to show how GPU memory can be used to send and receive packets - an useful tool to measure network metrics when using GPU memory with io forwarding With this feature test-gpudev can: - RX packets in CPU

[PATCH v2 0/1] app/test-gpudev: introduce ethdev to rx/tx packets using GPU memory

2021-11-18 Thread eagostini
From: Elena Agostini This patch introduces ethdev in test-gpudev app to provide: - an example to show how GPU memory can be used to send and receive packets - an useful tool to measure network metrics when using GPU memory with io forwarding With this feature test-gpudev can: - RX packets in CPU

[PATCH v1 1/1] app/test-gpudev: introduce ethdev to rx/tx packets using GPU memory

2021-11-17 Thread eagostini
From: Elena Agostini This patch introduces ethdev in test-gpudev app to provide: - an example to show how GPU memory can be used to send and receive packets - an useful tool to measure network metrics when using GPU memory with io forwarding With this feature test-gpudev can: - RX packets in CPU

[PATCH v1 0/1] app/test-gpudev: introduce ethdev to rx/tx packets using GPU memory

2021-11-17 Thread eagostini
From: Elena Agostini This patch introduces ethdev in test-gpudev app to provide: - an example to show how GPU memory can be used to send and receive packets - an useful tool to measure network metrics when using GPU memory with io forwarding With this feature test-gpudev can: - RX packets in CPU

[PATCH v2] app/test-gpudev: remove memory leaks in case of errors

2021-11-17 Thread eagostini
From: Elena Agostini Signed-off-by: Elena Agostini --- app/test-gpudev/main.c | 13 - 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/app/test-gpudev/main.c b/app/test-gpudev/main.c index c647e30de4..250fba6427 100644 --- a/app/test-gpudev/main.c +++ b/app/test-gpudev/

[PATCH v4 1/1] app/testpmd: add GPU memory option for mbuf pools

2021-11-17 Thread eagostini
From: Elena Agostini This patch introduces GPU memory in testpmd through the gpudev library. Testpmd can be used for network benchmarks when using GPU memory instead of regular CPU memory to send and receive packets. This option is currently limited to iofwd engine to ensure no workload is applie

[PATCH v4 0/1] app/testpmd: add GPU memory option for mbuf pools

2021-11-17 Thread eagostini
From: Elena Agostini This patch introduces GPU memory in testpmd through the gpudev library. Testpmd can be used for network benchmarks when using GPU memory instead of regular CPU memory to send and receive packets. This option is currently limited to iofwd engine to ensure no workload is applie

[PATCH v2] build: make gpudev optional

2021-11-17 Thread eagostini
From: Elena Agostini This library can be made optional. drivers/gpu and app/test-gpudev depend on this library, so there is a check for dependencies. Signed-off-by: Elena Agostini --- app/test-gpudev/meson.build | 1 + doc/guides/prog_guide/gpudev.rst | 1 + drivers/gpu/meson.build

[PATCH v1] app/test-gpudev: remove memory leaks in case of errors

2021-11-17 Thread eagostini
From: Elena Agostini Signed-off-by: Elena Agostini --- app/test-gpudev/main.c | 41 - 1 file changed, 28 insertions(+), 13 deletions(-) diff --git a/app/test-gpudev/main.c b/app/test-gpudev/main.c index c647e30de4..fe5c1e5b15 100644 --- a/app/test-gpudev

[PATCH v1] build: make gpudev optional

2021-11-17 Thread eagostini
From: Elena Agostini This library can be made optional. drivers/gpu and app/test-gpudev depend on this library, so there is a check for dependencies. Signed-off-by: Elena Agostini --- app/test-gpudev/meson.build | 11 +-- doc/guides/prog_guide/gpudev.rst | 1 + drivers/gpu/meson.

[PATCH v3 1/1] app/testpmd: add GPU memory option for mbuf pools

2021-11-16 Thread eagostini
From: Elena Agostini This patch introduces GPU memory in testpmd through the gpudev library. Testpmd can be used for network benchmarks when using GPU memory instead of regular CPU memory to send and receive packets. This option is currently limited to iofwd engine to ensure no workload is applie

[PATCH v3 0/1] app/testpmd: add GPU memory option for mbuf pools

2021-11-16 Thread eagostini
From: Elena Agostini This patch introduces GPU memory in testpmd through the gpudev library. Testpmd can be used for network benchmarks when using GPU memory instead of regular CPU memory to send and receive packets. This option is currently limited to iofwd engine to ensure no workload is applie

[PATCH v7 1/1] gpu/cuda: introduce CUDA driver

2021-11-16 Thread eagostini
From: Elena Agostini This is the CUDA implementation of the gpudev library. Functionalities implemented through CUDA Driver API are: - Device probe and remove - Manage device memory allocations - Register/unregister external CPU memory in the device memory area Signed-off-by: Elena Agostini ---

[PATCH v7 0/1] gpu/cuda: introduce CUDA driver

2021-11-16 Thread eagostini
From: Elena Agostini This is the CUDA implementation of the gpudev library. Funcitonalities implemented through CUDA Driver API are: - Device probe and remove - Manage device memory allocations - Register/unregister external CPU memory in the device memory area Changelog: - CUDA driver implemen

[PATCH v6 1/1] gpu/cuda: introduce CUDA driver

2021-11-16 Thread eagostini
From: Elena Agostini This is the CUDA implementation of the gpudev library. Functionalities implemented through CUDA Driver API are: - Device probe and remove - Manage device memory allocations - Register/unregister external CPU memory in the device memory area Signed-off-by: Elena Agostini ---

[PATCH v6 0/1] gpu/cuda: introduce CUDA driver

2021-11-16 Thread eagostini
From: Elena Agostini This is the CUDA implementation of the gpudev library. Funcitonalities implemented through CUDA Driver API are: - Device probe and remove - Manage device memory allocations - Register/unregister external CPU memory in the device memory area Changelog: - CUDA driver implemen

[PATCH v1] app/test-gpudev: improve tests' output

2021-11-15 Thread eagostini
From: Elena Agostini Signed-off-by: Elena Agostini --- app/test-gpudev/main.c | 90 ++ 1 file changed, 55 insertions(+), 35 deletions(-) diff --git a/app/test-gpudev/main.c b/app/test-gpudev/main.c index 1db3f69e10..e42133b3aa 100644 --- a/app/test-gpude

[PATCH v5 1/1] gpu/cuda: introduce CUDA driver

2021-11-15 Thread eagostini
From: Elena Agostini This is the CUDA implementation of the gpudev library. Funcitonalities implemented through CUDA Driver API are: - Device probe and remove - Manage device memory allocations - Register/unregister external CPU memory in the device memory area Signed-off-by: Elena Agostini --

[PATCH v5 0/1] gpu/cuda: introduce CUDA driver

2021-11-15 Thread eagostini
From: Elena Agostini This is the CUDA implementation of the gpudev library. Funcitonalities implemented through CUDA Driver API are: - Device probe and remove - Manage device memory allocations - Register/unregister external CPU memory in the device memory area Changelog: - CUDA driver implemen

[PATCH v2 1/1] app/testpmd: add GPU memory option in iofwd engine

2021-11-11 Thread eagostini
From: eagostini This patch introduces GPU memory in testpmd through the gpudev library. Testpmd can be used for network benchmarks when using GPU memory instead of regular CPU memory to send and receive packets. This option is currently limited to iofwd engine. Signed-off-by: Elena Agostini

[PATCH v2 0/1] app/testpmd: add GPU memory option in iofwd engine

2021-11-11 Thread eagostini
latest gpudev API eagostini (1): app/testpmd: add GPU memory option in iofwd engine app/test-pmd/cmdline.c| 14 +++ app/test-pmd/meson.build | 2 +- app/test-pmd/parameters.c | 13 ++- app/test-pmd/testpmd.c| 133

[dpdk-dev] [PATCH v3 8/9] gpudev: add communication list

2021-10-08 Thread eagostini
From: Elena Agostini In heterogeneous computing system, processing is not only in the CPU. Some tasks can be delegated to devices working in parallel. When mixing network activity with task processing there may be the need to put in communication the CPU with the device in order to synchronize op

[dpdk-dev] [PATCH v3 7/9] gpudev: add communication flag

2021-10-08 Thread eagostini
From: Elena Agostini In heterogeneous computing system, processing is not only in the CPU. Some tasks can be delegated to devices working in parallel. When mixing network activity with task processing there may be the need to put in communication the CPU with the device in order to synchronize op

[dpdk-dev] [PATCH v3 6/9] gpudev: add memory barrier

2021-10-08 Thread eagostini
From: Elena Agostini Add a function for the application to ensure the coherency of the writes executed by another device into the GPU memory. Signed-off-by: Elena Agostini --- doc/guides/prog_guide/gpudev.rst | 8 lib/gpudev/gpudev.c | 19 +++ lib/gpudev/

[dpdk-dev] [PATCH v3 9/9] doc: add CUDA example in GPU guide

2021-10-08 Thread eagostini
From: Elena Agostini Signed-off-by: Elena Agostini --- doc/guides/prog_guide/gpudev.rst | 122 +++ 1 file changed, 122 insertions(+) diff --git a/doc/guides/prog_guide/gpudev.rst b/doc/guides/prog_guide/gpudev.rst index cbaec5a1e4..1baf0c6772 100644 --- a/doc/guides

[dpdk-dev] [PATCH v3 0/9] GPU library

2021-10-08 Thread eagostini
From: eagostini In heterogeneous computing system, processing is not only in the CPU. Some tasks can be delegated to devices working in parallel. The goal of this new library is to enhance the collaboration between DPDK, that's primarily a CPU framework, and GPU devices. When mixing ne

[dpdk-dev] [PATCH v3 5/9] gpudev: add memory API

2021-10-08 Thread eagostini
From: Elena Agostini In heterogeneous computing system, processing is not only in the CPU. Some tasks can be delegated to devices working in parallel. Such workload distribution can be achieved by sharing some memory. As a first step, the features are focused on memory management. A function all

[dpdk-dev] [PATCH v3 1/9] gpudev: introduce GPU device class library

2021-10-08 Thread eagostini
From: Elena Agostini In heterogeneous computing system, processing is not only in the CPU. Some tasks can be delegated to devices working in parallel. The new library gpudev is for dealing with GPGPU computing devices from a DPDK application running on the CPU. The infrastructure is prepared to

[dpdk-dev] [PATCH v3 4/9] gpudev: support multi-process

2021-10-08 Thread eagostini
From: Thomas Monjalon The device data shared between processes are moved in a struct allocated in a shared memory (a new memzone for all GPUs). The main struct rte_gpu references the shared memory via the pointer mpshared. The API function rte_gpu_attach() is added to attach a device from the se

[dpdk-dev] [PATCH v3 3/9] gpudev: add child device representing a device context

2021-10-08 Thread eagostini
From: Thomas Monjalon The computing device may operate in some isolated contexts. Memory and processing are isolated in a silo represented by a child device. The context is provided as an opaque by the caller of rte_gpu_add_child(). Signed-off-by: Thomas Monjalon --- doc/guides/prog_guide/gpud

[dpdk-dev] [PATCH v3 2/9] gpudev: add event notification

2021-10-08 Thread eagostini
From: Thomas Monjalon Callback functions may be registered for a device event. Callback management is per-process and not thread-safe. The events RTE_GPU_EVENT_NEW and RTE_GPU_EVENT_DEL are notified respectively after creation and before removal of a device, as part of the library functions. Som

[dpdk-dev] [RFC PATCH] gpu/cuda: introduce CUDA driver

2021-10-05 Thread eagostini
From: Elena Agostini This is the CUDA implementation of the gpudev library. Funcitonalities implemented through CUDA Driver API are: - Device probe and remove - Manage device memory allocations - Register/unregister external CPU memory in the device memory area Signed-off-by: Elena Agostini --