-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Ignore trailing kernel module annotation #1413
Conversation
Does the same thing and less code to maintain.
This helper makes a lot of assumptions about the input and probably shouldn't be a public API if we can help it. Also rename the lower level helper b/c it doesn't look like function overloading works correctly with class member and non-class member.
Before, `find_wildcard_matches` would choke on lines in available_filter_functions like: ehci_disable_ASE [ehci_hcd] This patch has k[ret]probes ignore the module annotation. This closes bpftrace#1036 .
Ah nice you beat me to it. Wonder if it makes sense to define kprobes like |
Yeah, I think Do you think the following rules make sense?
Or is this too complicated? The alternative is to abandon the logic changes in this PR (the cleanup commits I think are still good) and always require module param to be specified if you want to include module kprobes. |
Sounds good
I think we should land this asap, we can always refactor it later. There is quite a lot of duplicate code between the listing and the function finding and kaddr/ksym expansion that we can clean up and simplify. |
Hi, I wonder if there has been any progress or plans on this feature? It is exactly what we need recently. Thanks! |
Hi, there is now support for this syntax for kfunc probes, i.e. |
Functionally, |
Yes, it requires kernel 5.5+ with BTF support, if you call that new :-). Since we have this functionality, we don't plan to duplicate it for kprobes. If you want to do it yourself, you can get inspired by the kfunc implementation for some parts. The main difference will be in the way probes are attached. While kfunc specifies the target module/function upon BPF program loading, kprobes do that during the attachment itself. So, you'll have to check if (and how) BCC's |
Thanks for the information :-). I will give feedback if there is any progress on this in the future. |
Before,
find_wildcard_matches
would choke on linesavailable_filter_functions like:
This patch has k[ret]probes ignore the module annotation.
This closes #1036 .
Checklist
docs/reference_guide.md
CHANGELOG.md