diff options
author | Yonghong Song <yhs@fb.com> | 2020-05-09 10:59:00 -0700 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2020-05-09 17:05:26 -0700 |
commit | 15d83c4d7cef5c067a8b075ce59e97df4f60706e (patch) | |
tree | b6baafd12655fe3a8d53f8db5d87fcfb95de4559 /include/linux/bpf_types.h | |
parent | bpf: Implement an interface to register bpf_iter targets (diff) | |
download | wireguard-linux-15d83c4d7cef5c067a8b075ce59e97df4f60706e.tar.xz wireguard-linux-15d83c4d7cef5c067a8b075ce59e97df4f60706e.zip |
bpf: Allow loading of a bpf_iter program
A bpf_iter program is a tracing program with attach type
BPF_TRACE_ITER. The load attribute
attach_btf_id
is used by the verifier against a particular kernel function,
which represents a target, e.g., __bpf_iter__bpf_map
for target bpf_map which is implemented later.
The program return value must be 0 or 1 for now.
0 : successful, except potential seq_file buffer overflow
which is handled by seq_file reader.
1 : request to restart the same object
In the future, other return values may be used for filtering or
teminating the iterator.
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/20200509175900.2474947-1-yhs@fb.com
Diffstat (limited to 'include/linux/bpf_types.h')
0 files changed, 0 insertions, 0 deletions