Commit 22166d00 authored by yonghong-song's avatar yonghong-song Committed by GitHub

Merge pull request #1681 from jcanseco/filetop_inlining

filetop: probe vfs_read and vfs_write instead to fix inlining issue
parents 7c27c271 6d818b68
......@@ -158,12 +158,8 @@ if debug or args.ebpf:
# initialize BPF
b = BPF(text=bpf_text)
b.attach_kprobe(event="__vfs_read", fn_name="trace_read_entry")
try:
b.attach_kprobe(event="__vfs_write", fn_name="trace_write_entry")
except:
# older kernels don't have __vfs_write so try vfs_write instead
b.attach_kprobe(event="vfs_write", fn_name="trace_write_entry")
b.attach_kprobe(event="vfs_read", fn_name="trace_read_entry")
b.attach_kprobe(event="vfs_write", fn_name="trace_write_entry")
DNAME_INLINE_LEN = 32 # linux/dcache.h
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment