Hi Morten, Look rte_memzone_reserve/rte_memzone_lookup
On Fri, Sep 13, 2019 at 4:32 PM Morten Brørup <m...@smartsharesystems.com> wrote: > > Hi Anatoly, > > > > The functions in the DPDK malloc library takes a "type" parameter (a string, > supposedly for debug purposes), but the underlying malloc_heap functions > (which take the same string parameter) don't store or use this string for > anything. > > > > Is the intention to implement this sometime in the future, or should it be > considered for removal? > > > > I was originally looking for a function for my primary process to allocate a > block of named memory in the huge-page area, so my secondary process could > look it up and use it. And I would simply use a unique type string for this, > and add an rte_malloc_lookup function. However, that obviously doesn't work > when the type parameter is not used during allocation. > > > > > > The simplest workaround I can come up with is using a named mempool with a > single element, where this element is my memory block. I get an element from > this mempool to find the address of my memory block, store the address, and > put the element back in the mempool, so the secondary process can get the > address the same way, i.e. by getting and putting the element back into the > mempool while storing the element's address underway. > > > > Any better ideas? > > > > > > Med venlig hilsen / kind regards > > > > Morten Brørup > > CTO > > > > > > SmartShare Systems A/S > > Tonsbakken 16-18 > > DK-2740 Skovlunde > > Denmark > > > > Office +45 70 20 00 93 > > Direct +45 89 93 50 22 > > Mobile +45 25 40 82 12 > > > > m...@smartsharesystems.com <mailto:m...@smartsharesystems.com> > > www.smartsharesystems.com <https://www.smartsharesystems.com/> > > >