Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Zero-copy in most NICs? #1447

Open
gorgonical opened this issue Oct 30, 2019 · 2 comments
Open

Zero-copy in most NICs? #1447

gorgonical opened this issue Oct 30, 2019 · 2 comments

Comments

@gorgonical
Copy link

gorgonical commented Oct 30, 2019

I couldn't find anything in the docs or the code that confirmed this question, so I figured I would ask. I would have asked in the Slack but the invite link is broken.

Does Snabb provide zero-copy semantics for NICs? I know that the memory module provides DMA memory for the NIC to access and the usage in some parts of the code such as:

src/apps/intel_mp/intel_mp.lua:555:   memory.dma_alloc(ffi.sizeof(rxdesc_ring_t)))
src/apps/intel_mp/intel_mp.lua:625:   memory.dma_alloc(ffi.sizeof(txdesc_ring_t)))

indicate that the DMA memory is being used for the NIC queues, but I wanted to be sure.

@gorgonical gorgonical changed the title Zero-copy in most NICs Zero-copy in most NICs? Oct 30, 2019
@eugeneia
Copy link
Member

eugeneia commented Nov 3, 2019

Yes, that is what we do. I.e., let the hardware write to and read from our struct packet buffers in DMA memory directly.

lukego/blog#13 might give slightly more detail from the OS perspective.

@eugeneia
Copy link
Member

The invite link should work again btw. :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants