Commit Graph

35 Commits (7ccc027de589e87e9401df6b0e12751d70957941)

Author SHA1 Message Date
Michal Rostecki dad75f45ac Update Tokio and inventory
Signed-off-by: Michal Rostecki <vadorovsky@gmail.com>
2 years ago
Shenghui Ye 9c451a3357 aya-obj: update documentation and versioning info
- Set the version number of `aya-obj` to `0.1.0`.
- Update the description of the `aya-obj` crate.
- Add a section in README and rustdoc warning about the unstable API.
2 years ago
Shenghui Ye 81bc307dce aya-obj: migrate bindgen destination
Aya::obj depends on bindgen generated files, and we start
by migrating bindgen generated files.

This commit adds the new aya-obj crate to the workplace
and migrates generated files into the crate. We use core
instead of std in an effort to make the final crate no_std.

Bindgen was run against libbpf v1.0.1.

Refs: #473
2 years ago
dependabot[bot] 1fe7bba070
build(deps): update object requirement from 0.29 to 0.30
Updates the requirements on [object](https://github.com/gimli-rs/object) to permit the latest version.
- [Release notes](https://github.com/gimli-rs/object/releases)
- [Changelog](https://github.com/gimli-rs/object/blob/master/CHANGELOG.md)
- [Commits](https://github.com/gimli-rs/object/compare/0.29.0...0.30.0)

---
updated-dependencies:
- dependency-name: object
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2 years ago
Andrew Stoycos 82edd681c3 Fix doc links, update rustdoc args
Fix some broken rust doc links.

Make sure rustdoc build fail on warnings
so we catch these broken links in CI.

Signed-off-by: Andrew Stoycos <astoycos@redhat.com>
2 years ago
Dave Tucker ec2bd69053 cargo: Remove unused dependencies
Signed-off-by: Dave Tucker <dave@dtucker.co.uk>
2 years ago
Dave Tucker 95e8c78db8 docs: Add labels for optional features
Following the lead of crates like tokio and nix, we now annotate APIs
that require optional features. This helps in cases where a user wants
to have an `AsyncPerfEventArray` which is documented on crates.io, but
it's not obvious that you have to enable the `async` feature.

Signed-off-by: Dave Tucker <dave@dtucker.co.uk>
2 years ago
Michal Rostecki 944d6b8a16 Change from Rust edition 2018 to 2021
Rust 2021 adds more core prelude imports, including `TryFrom` and
`TryInto`.

Signed-off-by: Michal Rostecki <vadorovsky@gmail.com>
2 years ago
dependabot[bot] 661a21570f
build(deps): update object requirement from 0.28 to 0.29
Updates the requirements on [object](https://github.com/gimli-rs/object) to permit the latest version.
- [Release notes](https://github.com/gimli-rs/object/releases)
- [Changelog](https://github.com/gimli-rs/object/blob/master/CHANGELOG.md)
- [Commits](https://github.com/gimli-rs/object/compare/0.28.0...0.29.0)

---
updated-dependencies:
- dependency-name: object
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2 years ago
Alessandro Decina d85b36f6d8 (cargo-release) version 0.11.0 2 years ago
Alessandro Decina 4e57d1fe32 aya: revert version to 0.10.7
The world isn't ready to have pre-releases in git
3 years ago
Alessandro Decina cb57d10d25 aya: rework links
Remove LinkRef and remove the Rc<RefCell<_>> that was used to store
type-erased link values in ProgramData. Among other things, this allows
`Bpf` to be `Send`, which makes it easier to use it with async runtimes.

Change the link API to:

    let link_id = prog.attach(...)?;
    ...
    prog.detach(link_id)?;

Link ids are strongly typed, so it's impossible to eg:

    let link_id = uprobe.attach(...)?;
    xdp.detach(link_id);

As it would result in a compile time error.

Links are still stored inside ProgramData, and unless detached
explicitly, they are automatically detached when the parent program gets
dropped.
3 years ago
Alessandro Decina f01497e021 (cargo-release) version 0.10.7 3 years ago
dependabot[bot] ab7eed2759
build(deps): update parking_lot requirement from 0.11.1 to 0.12.0
Updates the requirements on [parking_lot](https://github.com/Amanieu/parking_lot) to permit the latest version.
- [Release notes](https://github.com/Amanieu/parking_lot/releases)
- [Changelog](https://github.com/Amanieu/parking_lot/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Amanieu/parking_lot/compare/0.11.1...0.12.0)

---
updated-dependencies:
- dependency-name: parking_lot
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
3 years ago
Dave Tucker 5c6131afba Add BPF_PROG_TYPE_EXT
This requires loading the BTF to kernel when loading all programs as
well as implementing Extension program type

Signed-off-by: Dave Tucker <dave@dtucker.co.uk>
3 years ago
dependabot[bot] 54b0c67795 build(deps): update object requirement from 0.27 to 0.28
Updates the requirements on [object](https://github.com/gimli-rs/object) to permit the latest version.
- [Release notes](https://github.com/gimli-rs/object/releases)
- [Changelog](https://github.com/gimli-rs/object/blob/master/CHANGELOG.md)
- [Commits](https://github.com/gimli-rs/object/compare/0.27.0...0.28.1)

---
updated-dependencies:
- dependency-name: object
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
3 years ago
Alessandro Decina 182182d840 (cargo-release) version 0.10.6 3 years ago
Tobias Klauser 2136f05461 aya: netlink: use NETLINK_EXT_ACK from libc crate
NETLINK_EXT_ACK is available since libc crate version 0.2.105, see
https://github.com/rust-lang/libc/releases/tag/0.2.105
3 years ago
dependabot[bot] c99dcfb9d3 build(deps): update object requirement from 0.26 to 0.27
Updates the requirements on [object](https://github.com/gimli-rs/object) to permit the latest version.
- [Release notes](https://github.com/gimli-rs/object/releases)
- [Changelog](https://github.com/gimli-rs/object/blob/master/CHANGELOG.md)
- [Commits](https://github.com/gimli-rs/object/compare/0.26.0...0.27.0)

---
updated-dependencies:
- dependency-name: object
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
3 years ago
Alessandro Decina 4152e8b1a4 (cargo-release) version 0.10.5 3 years ago
Alessandro Decina a7f5b3775d (cargo-release) version 0.10.4 3 years ago
Dave Tucker a10a7b3bf2 bump obj to 0.26
Signed-off-by: Dave Tucker <dave@dtucker.co.uk>
3 years ago
Alessandro Decina 9c27910f76 aya: update authors and repository link 3 years ago
Alessandro Decina f30abca15e (cargo-release) version 0.10.3 3 years ago
Alessandro Decina d70e291580 (cargo-release) version 0.10.2 3 years ago
Alessandro Decina 304abfbfeb (cargo-release) version 0.10.1 3 years ago
Alessandro Decina 7694bacf04 aya: add more fields to Cargo.toml 3 years ago
Alessandro Decina 9f7b017d5d aya: bump version to 0.10 3 years ago
Alessandro Decina 0cf5d17e38 deps: enable only the std feature for the futures crate 4 years ago
Alessandro Decina 55d8bcf386 xdp: add support for attaching with custom xdp flags 4 years ago
Alessandro Decina 873691d050 Trim deps a bit more 4 years ago
Alessandro Decina f1da541234 The futures crate is only needed when async is enabled 4 years ago
Alessandro Decina fdc4dad5ff maps: add AsyncPerfMap
When the async_tokio or async_std features are enabled, AsyncPerfMap
provides an async version of PerfMap which returns a future from
read_events()
4 years ago
Alessandro Decina d4e282535b bpf, perf_map: make maps usable from multiple threads
Change PerfMap API so that individual buffers can be read from multiple
threads.

Change the way maps are stored in the `Bpf` struct from RefCell to a
custom RwLock.
4 years ago
Alessandro Decina af8f769b50 Turn the project into a workspace, move code under aya/ 4 years ago