* [dpdk-dev] Decoupling rte_mbuf and the segment buffer.
@ 2018-09-24 11:44 Wojciech Waśko
0 siblings, 0 replies; only message in thread
From: Wojciech Waśko @ 2018-09-24 11:44 UTC (permalink / raw)
To: dev
I've been wondering about the possibility to decouple the mbuf header
(and the private data) from the payload. If I'm reading the code
correctly, right now the payload is placed (together with the header and
the private data) in one memory object dequeued from the mempool.
I can use a specific mempool for pktbuf_pool by using
rte_pktmbuf_pool_create_by_ops(). However, there is no way to have the
header and buffer go to separate mempools, is that correct?
As I see that struct rte_mbuf contains a pointer to the segment buffer
(both VA and PA) and rte_pktmbuf_init() initializes those pointers. So
one could expect that the rest of DPDK would not depend on the fact that
the segment buffer is at some offset from the mbuf header, right?
I was also looking at the rte_pktmbuf_attach_extbuf() patches from
April. It seems that I could spin up my own (possibly non-RTE) memory
pool and then rte_mempool_obj_iter() the pktbuf_pool to attach external
buffers to all the mbufs in the original pool. The obvious downside here
would be that some memory would be wasted in the mbuf pool (because the
segment buffer would be allocated but unused) but in principle that
should also work, right? Can you think of any other obvious downsides to
that approach?
Regards,
Wojtek
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2018-09-24 11:44 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-09-24 11:44 [dpdk-dev] Decoupling rte_mbuf and the segment buffer Wojciech Waśko
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).