bpf: Create file bpf iterator
authorYonghong Song <yhs@fb.com>
Sat, 9 May 2020 17:59:06 +0000 (10:59 -0700)
committerAlexei Starovoitov <ast@kernel.org>
Sun, 10 May 2020 00:05:26 +0000 (17:05 -0700)
commit367ec3e4834cbd611401c2c40a23c22c825474f1
tree168079defa34ecb2b4860c765de8639bc001c222
parentac51d99bf81caac8d8881fe52098948110d0de68
bpf: Create file bpf iterator

To produce a file bpf iterator, the fd must be
corresponding to a link_fd assocciated with a
trace/iter program. When the pinned file is
opened, a seq_file will be generated.

Signed-off-by: Yonghong Song <yhs@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Acked-by: Andrii Nakryiko <andriin@fb.com>
Link: https://lore.kernel.org/bpf/20200509175906.2475893-1-yhs@fb.com
include/linux/bpf.h
kernel/bpf/bpf_iter.c
kernel/bpf/inode.c