]> git.baikalelectronics.ru Git - kernel.git/commit
samples/bpf: add example to test reading address
authorTeng Qin <qinteng@fb.com>
Tue, 6 Mar 2018 18:55:02 +0000 (10:55 -0800)
committerDaniel Borkmann <daniel@iogearbox.net>
Thu, 8 Mar 2018 01:22:34 +0000 (02:22 +0100)
commitd987aa968d9b4a4d4d11ee3f1bbe22b0633dfedc
tree822b9bb7680c97b84f98f8d471b297637048d473
parent27f2790a15d40b03fd322729fa54e7a02ee7b087
samples/bpf: add example to test reading address

This commit adds additional test in the trace_event example, by
attaching the bpf program to MEM_UOPS_RETIRED.LOCK_LOADS event with
PERF_SAMPLE_ADDR requested, and print the lock address value read from
the bpf program to trace_pipe.

Signed-off-by: Teng Qin <qinteng@fb.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
samples/bpf/trace_event_kern.c
samples/bpf/trace_event_user.c