diff options
author | Roberto Sassu <[email protected]> | 2022-10-06 13:07:34 +0200 |
---|---|---|
committer | Andrii Nakryiko <[email protected]> | 2022-10-10 16:49:20 -0700 |
commit | 2ce7cbf2ba71bb03542af739af80e86b6855ae48 (patch) | |
tree | a21109d37bea2592151d215a13333659ac2054a2 /tools/testing/selftests/bpf/prog_tests/prog_array_init.c | |
parent | 8f13f168ea14333ac971e5404800b7fb3658e782 (diff) |
libbpf: Introduce bpf_btf_get_fd_by_id_opts()
Introduce bpf_btf_get_fd_by_id_opts(), for symmetry with
bpf_map_get_fd_by_id_opts(), to let the caller pass the newly introduced
data structure bpf_get_fd_by_id_opts. Keep the existing
bpf_btf_get_fd_by_id(), and call bpf_btf_get_fd_by_id_opts() with NULL as
opts argument, to prevent setting open_flags.
Currently, the kernel does not support non-zero open_flags for
bpf_btf_get_fd_by_id_opts(), and a call with them will result in an error
returned by the bpf() system call. The caller should always pass zero
open_flags.
Signed-off-by: Roberto Sassu <[email protected]>
Signed-off-by: Andrii Nakryiko <[email protected]>
Link: https://lore.kernel.org/bpf/[email protected]
Diffstat (limited to 'tools/testing/selftests/bpf/prog_tests/prog_array_init.c')
0 files changed, 0 insertions, 0 deletions