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

aya,aya-ebpf: implement RingBuf #629

Merged
merged 3 commits into from
Oct 12, 2023
Merged

aya,aya-ebpf: implement RingBuf #629

merged 3 commits into from
Oct 12, 2023

Commits on Oct 11, 2023

  1. Configuration menu
    Copy the full SHA
    b73c0a4 View commit details
    Browse the repository at this point in the history
  2. aya: move mmap from perf_buffer.rs to sys/mod.rs

    mmap() is needed for the ring buffer implementation, so move it to a common module
    willfindlay authored and tamird committed Oct 11, 2023
    Configuration menu
    Copy the full SHA
    4af9d1b View commit details
    Browse the repository at this point in the history
  3. aya: Implement RingBuf

    This implements the userspace binding for RingBuf.
    
    Instead of streaming the samples as heap buffers, the process_ring
    function takes a callback to which we pass the event's byte region,
    roughly following [libbpf]'s API design. This avoids a copy and allows
    marking the consumer pointer in a timely manner.
    
    [libbpf]: https://github.com/libbpf/libbpf/blob/master/src/ringbuf.c
    
    Additionally, integration tests are added to demonstrate the usage
    of the new APIs and to ensure that they work end-to-end.
    
    Co-authored-by: William Findlay <[email protected]>
    Co-authored-by: Tatsuyuki Ishi <[email protected]>
    3 people committed Oct 11, 2023
    Configuration menu
    Copy the full SHA
    e2cf734 View commit details
    Browse the repository at this point in the history