Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Use explicit attach_type to create tracing link
It's for strace to trace BPF syscall, like: ```bash $ sudo /root/strace/src/strace --trace=bpf -f ./vista --filter-trace-xdp --filter-trace-tc --output-meta --output-tuple --output-limit-lines 4 --pcap-file vista.pcapng icmp [pid 3742661] bpf(BPF_LINK_CREATE, {link_create={prog_fd=40, target_fd=0, attach_type=BPF_TRACE_FENTRY, flags=0, tracing={}}}, 64) = 31 [pid 3742661] bpf(BPF_LINK_CREATE, {link_create={prog_fd=38, target_fd=0, attach_type=BPF_TRACE_FEXIT, flags=0, tracing={}}}, 64) = 41 [pid 3742655] bpf(BPF_LINK_CREATE, {link_create={prog_fd=39, target_fd=0, attach_type=BPF_TRACE_FENTRY, flags=0, tracing={}}}, 64) = 22 [pid 3742655] bpf(BPF_LINK_CREATE, {link_create={prog_fd=21, target_fd=0, attach_type=BPF_TRACE_FEXIT, flags=0, tracing={}}}, 64) = 23 [pid 3742655] bpf(BPF_LINK_CREATE, {link_create={prog_fd=30, target_fd=0, attach_type=BPF_TRACE_FENTRY, flags=0, tracing={}}}, 64) = 29 [pid 3742655] bpf(BPF_LINK_CREATE, {link_create={prog_fd=32, target_fd=0, attach_type=BPF_TRACE_FEXIT, flags=0, tracing={}}}, 64) = 33 ``` Signed-off-by: Leon Hwang <[email protected]>
- Loading branch information