All of lore.kernel.org
 help / color / mirror / Atom feed
* [SPDK] Re: Shared memory allocated spdk_dma_malloc from among process
@ 2022-10-21  0:26 Cao, Gang
  0 siblings, 0 replies; only message in thread
From: Cao, Gang @ 2022-10-21  0:26 UTC (permalink / raw)
  To: spdk

[-- Attachment #1: Type: text/plain, Size: 1460 bytes --]

SPDK underlying layer also supports the multi process mode based on DPDK's capability.

You may take a look at https://spdk.io/doc/nvme.html#nvme_multi_process

Also for the usage of spdk_dma_malloc, you may take a look at the multi process related APIs like spdk_memzone... and spdk_mempool... which will also call the rte_memzone... and rte_mempool... APIs.

Thanks.

-----Original Message-----
From: Lego Lin <lego.lin(a)gmail.com> 
Sent: Thursday, October 20, 2022 23:32
To: Storage Performance Development Kit <spdk(a)lists.01.org>
Subject: [SPDK] Shared memory allocated spdk_dma_malloc from among process

Hi, all:

Can anyone give me some guidelines that how to share memory from spdk_dma_malloc among 2 processes?

I know how to use shm_open / mmap to create and share memory among processes.
It looks like DPDK memzone can be shared among processes through it's internal API (rte_memzone_lookup / dump_memzone) But I didn't find obvious clues about sharing memory from spdk_dma_malloc to another process.
My idea is Process A get the physical address of memory from spdk_dma_malloc.
Process A put these physical address to a shared memory.
Process B get physical address from shared memory and map them to virtual space of process B.

Is there other ways to do this?

Thanks
_______________________________________________
SPDK mailing list -- spdk(a)lists.01.org
To unsubscribe send an email to spdk-leave(a)lists.01.org

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-10-21  0:26 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-21  0:26 [SPDK] Re: Shared memory allocated spdk_dma_malloc from among process Cao, Gang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.