-
Notifications
You must be signed in to change notification settings - Fork 39
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
fix: move to new bpf api #47
Conversation
Should you also update https://github.com/springzfx/cgproxy/blob/master/execsnoop-kernel/aarch64/execsnoop_kern_skel.h ? |
I don't have any arm device TAT. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@black-desk PTAL.
pb_opts.sample_cb = handle_event; | ||
pb_opts.lost_cb = handle_lost_events; | ||
pb = perf_buffer__new(bpf_map__fd(obj->maps.perf_events), PERF_BUFFER_PAGES, &pb_opts); | ||
pb = perf_buffer__new(bpf_map__fd(obj->maps.perf_events), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I look into libbpf source, seems like this opts just use to do a check, and not passed into __perf_buffer__new
:
this check will success when opts is nullptr:
so it will be fine whether pass opts or nullptr.
I have no idea why libbpf need this opts arg.
Shall we fork this repo and maintain that one instead? |
execsnoop_kern_skel.h for aarch64(without test) |
Works for libbpf 1.x now. Thanks for your contribution. |
No description provided.