Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-11-08 Thread Rajesh Ravi
Thanks David. With Anatoly's patch applied my patch is not needed as the purpose is solved. Regards, Rajesh On Thu, Nov 7, 2019 at 9:21 PM David Marchand wrote: > On Wed, Nov 6, 2019 at 2:55 PM David Marchand > wrote: > > > > On Tue, Nov 5, 2019 at 6:14 PM Burakov, Anatoly > > wrote: > > >

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-11-07 Thread David Marchand
On Wed, Nov 6, 2019 at 2:55 PM David Marchand wrote: > > On Tue, Nov 5, 2019 at 6:14 PM Burakov, Anatoly > wrote: > > > > On 05-Nov-19 3:18 PM, Burakov, Anatoly wrote: > > > On 05-Nov-19 2:10 PM, Rajesh Ravi wrote: > > >> Thanks a lot Anatoly. > > >> Will the same solution work with DPDK 19.02 a

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-11-06 Thread Rajesh Ravi
Thanks a lot Anatoly. Will the same solution work with DPDK 19.02 as well? We 're actually using DPDK 19.02 for memory allocations for SPDK 19.07. DPDK 19.11 may not be supported by SPDK 19.07 we 're currently using. I 'll definitely test if the patch works with DPDK 19.02 Thanks again for your

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-11-06 Thread David Marchand
On Tue, Nov 5, 2019 at 6:14 PM Burakov, Anatoly wrote: > > On 05-Nov-19 3:18 PM, Burakov, Anatoly wrote: > > On 05-Nov-19 2:10 PM, Rajesh Ravi wrote: > >> Thanks a lot Anatoly. > >> Will the same solution work with DPDK 19.02 as well? We 're actually > >> using DPDK 19.02 for memory allocations f

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-11-05 Thread Burakov, Anatoly
On 05-Nov-19 3:18 PM, Burakov, Anatoly wrote: On 05-Nov-19 2:10 PM, Rajesh Ravi wrote: Thanks a lot Anatoly. Will the same solution work with  DPDK 19.02 as well? We 're actually using DPDK 19.02 for memory allocations for SPDK 19.07. DPDK 19.11 may not be supported by SPDK 19.07 we 're curren

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-11-05 Thread Burakov, Anatoly
On 05-Nov-19 2:10 PM, Rajesh Ravi wrote: Thanks a lot Anatoly. Will the same solution work with  DPDK 19.02 as well? We 're actually using DPDK 19.02 for memory allocations for SPDK 19.07. DPDK 19.11 may not be supported by SPDK 19.07 we 're currently using. I 'll definitely test if the patch

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-11-05 Thread Burakov, Anatoly
On 04-Nov-19 10:25 AM, Burakov, Anatoly wrote: On 30-Oct-19 7:50 PM, Rajesh Ravi wrote: Thanks Anatoly. Please find  inline below: [Anatoly] vfio_mem_event_callback() is called every time memory is added to a heap. That includes internal and external memory [Rajesh] malloc_heap_add_external_

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-11-04 Thread Burakov, Anatoly
On 30-Oct-19 7:50 PM, Rajesh Ravi wrote: Thanks Anatoly. Please find  inline below: [Anatoly] vfio_mem_event_callback() is called every time memory is added to a heap. That includes internal and external memory [Rajesh] malloc_heap_add_external_memory() does call eal_memalloc_mem_event_notif

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-11-02 Thread Rajesh Ravi
Thanks Anatoly. Please find inline below: [Anatoly] vfio_mem_event_callback() is called every time memory is added to a heap. That includes internal and external memory [Rajesh] malloc_heap_add_external_memory() does call eal_memalloc_mem_event_notify [ instead of vfio_mem_event_callback() ]

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-10-27 Thread Rajesh Ravi
Thanks Anatoly. I think now we 're close to sync. You understood it right: the problem is dma/iommu mappings are not getting created. 1)vfio_mem_event_callback() is getting called later when memory is allocated from heap but not when external memory is added to heap 2)vfio_dma_mem_map() is called

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-10-25 Thread Burakov, Anatoly
On 25-Oct-19 1:53 PM, Rajesh Ravi wrote: Thanks Anatoly. I think now we 're close to sync. You understood it right: the problem is dma/iommu mappings are not getting created. 1)vfio_mem_event_callback() is getting called later when memory is allocated from heap but not when external memory is

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-10-24 Thread Burakov, Anatoly
On 22-Oct-19 8:56 AM, Rajesh Ravi wrote: Hi Anatoly, I tried calling rte_vfio_dma_map() but, it  failed for me because vfio_dma_mem_map() failed with error:VFIO support not initialized because: default_vfio_cfg->vfio_iommu_type=NULL ( container_dma_map calls vfio_dma_mem_map  with vfio_cfg =

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-10-23 Thread Rajesh Ravi
Hi Anatoly, I tried calling rte_vfio_dma_map() but, it failed for me because vfio_dma_mem_map() failed with error:VFIO support not initialized because: default_vfio_cfg->vfio_iommu_type=NULL ( container_dma_map calls vfio_dma_mem_map with vfio_cfg = default_vfio_cfg ) call sequence: rte_vfio

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-10-23 Thread Rajesh Ravi
Thanks Anatoly for prompt response. Sorry for the delayed response, I took some time to reverify with SPDK. Infact, I do want the iommu mapping to be performed. I don't want it to be bypassed by type1_map() [lib/librte_eal/linuxapp/eal/eal_vfio.c] for external memory. Then, if I understood correc

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-10-21 Thread Rajesh Ravi
+ Srinath Thanks Anatoly for reviewing this. Please find my reply inline below: [Anatoly] First of all, what is "iso-cmem"? It doesn't seem to have any defined meaning nor any relation to any existing functionality, and it's not explained anywhere what is "isolated cmem". [Rajesh] I 'll correct

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-10-18 Thread Burakov, Anatoly
On 18-Oct-19 11:54 AM, Rajesh Ravi wrote: + Srinath Thanks Anatoly for reviewing this. Please find my reply inline  below: [Anatoly] First of all, what is "iso-cmem"? It doesn't seem to have any defined meaning nor any relation to any existing functionality, and it's not explained anywhere wh

Re: [dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-10-17 Thread Burakov, Anatoly
On 15-Oct-19 6:30 AM, Ajit Khaparde wrote: From: Rajesh Ravi Support external custom memory added to heap to be used with vfio with --iso-cmem option.Type1 memory mapping was by passed for external memory. But an exception is added to allow external custom memory to be used with vfio. Signed-o

[dpdk-dev] [PATCH] eal: add option --iso-cmem for external custom memory

2019-10-14 Thread Ajit Khaparde
From: Rajesh Ravi Support external custom memory added to heap to be used with vfio with --iso-cmem option.Type1 memory mapping was by passed for external memory. But an exception is added to allow external custom memory to be used with vfio. Signed-off-by: Rajesh Ravi Reviewed-by: Jonathan Ric