-
Notifications
You must be signed in to change notification settings - Fork 168
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
Add flag to attach to all available kernel modules #109
Conversation
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.
Thanks! LGTM, just two minor comments. Also, could you please sign off your commit? git commit --amend -s
should do the job.
main.go
Outdated
if flags.AllKMods { | ||
files, err := os.ReadDir("/sys/kernel/btf") | ||
if err != nil { | ||
log.Fatalf("Failed to read Directory: %s", err) |
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.
log.Fatalf("Failed to read Directory: %s", err) | |
log.Fatalf("Failed to read directory: %s", err) |
main.go
Outdated
|
||
flags.KMods = nil | ||
for _, file := range files { | ||
if !file.IsDir() { |
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.
You want to exclude vmlinux
here. Otherwise, it will be parsed twice.
Signed-off-by: varunkumare99 <varunkumare99@gmail.com>
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.
Thanks!
Thank you! |
added flag
--all-kmods
to attach to all available kernel modules.fix: #100