diff options
| author | Fuyu Zhao <zhaofuyu@vivo.com> | 2026-09-15 20:41:03 +0800 |
|---|---|---|
| committer | Andrii Nakryiko <andrii@kernel.org> | 2026-09-21 09:26:40 -0700 |
| commit | 34b1847924433ec088709d703bf3f93657e5a686 (patch) | |
| tree | a6193f24684feb7a65be810ea7075a635525cb3b /tools/testing/selftests/bpf/test_cpp.cpp | |
| parent | 6e36e099b15bed1e8e5b3e3136c5e3eb56a15aa7 (diff) | |
| download | linux-next-34b1847924433ec088709d703bf3f93657e5a686.tar.gz linux-next-34b1847924433ec088709d703bf3f93657e5a686.zip | |
libbpf: Support selective kernel module BTF loading via bpf_object_open_opts
Add btf_module_allowlist and btf_module_allowlist_cnt fields to
bpf_object_open_opts to limit which kernel module BTFs libbpf is
allowed to load.
When the option is not specified, the existing behavior remains
unchanged. An explicitly specified empty allowlist prevents libbpf from
consulting any kernel module BTFs.
The allowlist limits which kernel module BTFs libbpf will consult
wherever module BTF might be needed.
Suggested-by: Andrii Nakryiko <andrii@kernel.org>
Signed-off-by: Fuyu Zhao <zhaofuyu@vivo.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Link: https://lore.kernel.org/bpf/20260915124104.77287-2-zhaofuyu@vivo.com
Diffstat (limited to 'tools/testing/selftests/bpf/test_cpp.cpp')
0 files changed, 0 insertions, 0 deletions
