-
Notifications
You must be signed in to change notification settings - Fork 264
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-obj: conversion from u32
to prog, map, and link type
#979
Conversation
✅ Deploy Preview for aya-rs-docs ready!Built without sensitive environment variables
To edit notification comments on pull requests, go to your Netlify site configuration. |
Hey @alessandrod, this pull request changes the Aya Public API and requires your review. |
Adds conversion from u32 to `bpf_prog_type` so that the `type_` field in `bpf_prog_info` can map to the program type enum. This also implements Display for `bpf_prog_type` for condensed output format.
Removes duplicate u32 conversion for map type `BPF_MAP_TYPE_BLOOM_FILTER` and `BPF_MAP_TYPE_CGRP_STORAGE`, and adds `BPF_MAP_TYPE_CGRP_STORAGE`. Also implements display for map type.
Adds conversion from u32 to link type enum. Also implements display for condensed metadata output. So far, this is still WIP since this commit/PR also plans to add better access to `bpf_link_info__bindgen_ty_1` metadata.
66aa065
to
a35a513
Compare
So the scope of this PR expanded to include metadata info from |
u32
to prog, map, and link type
Add bpf syscall function for BPF_ENABLE_STATS to enable stats tracking for benchmarking purposes, which returns a file descriptor handler. This also adds the aya-object api for bpf_stats_type.
Added functions to expose run_time_ns & run_cnt statistics from ProgramInfo/bpf_prog_info.
I almost accidently deleted this PR bc of the branch name I had. Since the scope of this PR expanded, this will go under a new branch since the one I'm working on locally is wacky. |
I have a usecase that extracts program type information from from
bpf_prog_info
. 😺This PR adds conversion from
u32
tobpf_prog_type
so that thetype_
field inbpf_prog_info
can map to the program type enum. This also implements Display forbpf_prog_type
for condensed output format. 😺Also,
codegen
andpublic-api
appears to be acting a little funky for me.