Code Monkey home page Code Monkey logo

Comments (3)

glommer avatar glommer commented on August 24, 2024

I am not very familiar with raw ethernet. From the io_uring's point of view, what is it exactly that is needed?
To the best of my knowledge, io_uring itself will operate in a much higher level at the socket layer, no?

from glommio.

jamwaffles avatar jamwaffles commented on August 24, 2024

Because I have a RawFd, I can use that pretty much directly with io_uring. I wrote a quick blocking test which kind of works. The bit I'm stuck on is making it async. I figured glommio might have some prior art in this area I could build on top of.

So I guess to alter my original question a bit: can I read/write a RawFd (or OwnedFd or whatever) with glommio? If not, where could I look in the codebase for inspiration? The FD I'm using just happens to be hooked up to tx/rx raw ethernet packets but from io_uring's perspective it's just data.

from glommio.

glommer avatar glommer commented on August 24, 2024

The way I would do this, is at the sys/uring.rs level, try our best to either reuse the existing functions (open_at and one of the read/writes should work?), and if changes are made, try to make it in a way that we don't have special reads and writes just for that.

But at the API level (src/io), then have a specialized API that deals with raw file descriptors and keep as high level, specialized, and hard to misuse as possible (I wouldn't go as far as specializing to ethernet frames, but certainly to a rawfd - but that's mostly because I don't understand ethernet well, and don't see any benefit)

I don't think this exists today, so you'd have to add it.

from glommio.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.