Home
last modified time | relevance | path

Searched refs:btf_vmlinux (Results 1 – 7 of 7) sorted by relevance

/Linux-v5.10/tools/bpf/bpftool/
Dstruct_ops.c21 static struct btf *btf_vmlinux; variable
31 if (btf_vmlinux) in get_btf_vmlinux()
32 return btf_vmlinux; in get_btf_vmlinux()
34 btf_vmlinux = libbpf_find_kernel_btf(); in get_btf_vmlinux()
35 if (IS_ERR(btf_vmlinux)) in get_btf_vmlinux()
38 return btf_vmlinux; in get_btf_vmlinux()
599 if (!IS_ERR(btf_vmlinux)) in do_struct_ops()
600 btf__free(btf_vmlinux); in do_struct_ops()
Dmap.c793 static struct btf *btf_vmlinux; variable
800 if (!btf_vmlinux) { in get_map_kv_btf()
801 btf_vmlinux = libbpf_find_kernel_btf(); in get_map_kv_btf()
802 if (IS_ERR(btf_vmlinux)) in get_map_kv_btf()
805 return btf_vmlinux; in get_map_kv_btf()
821 if (!IS_ERR(btf) && btf != btf_vmlinux) in free_map_kv_btf()
827 if (!IS_ERR(btf_vmlinux)) in free_btf_vmlinux()
828 btf__free(btf_vmlinux); in free_btf_vmlinux()
/Linux-v5.10/kernel/bpf/
Dbpf_struct_ops.c198 extern struct btf *btf_vmlinux;
205 if (!value_id || !btf_vmlinux) in bpf_struct_ops_find_value()
220 if (!type_id || !btf_vmlinux) in bpf_struct_ops_find()
300 mtype = btf_type_by_id(btf_vmlinux, member->type); in check_zero_holes()
301 mtype = btf_resolve_size(btf_vmlinux, mtype, &msize); in check_zero_holes()
372 ptype = btf_type_resolve_ptr(btf_vmlinux, member->type, NULL); in bpf_struct_ops_map_update_elem()
397 mtype = btf_type_by_id(btf_vmlinux, member->type); in bpf_struct_ops_map_update_elem()
398 mtype = btf_resolve_size(btf_vmlinux, mtype, &msize); in bpf_struct_ops_map_update_elem()
520 btf_type_seq_show(btf_vmlinux, map->btf_vmlinux_value_type_id, in bpf_struct_ops_map_seq_show_elem()
Dbtf.c4198 extern struct btf *btf_vmlinux;
4268 ctx_struct = btf_type_by_id(btf_vmlinux, ctx_type->type); in btf_get_prog_ctx_type()
4272 ctx_tname = btf_name_by_offset(btf_vmlinux, ctx_struct->name_off); in btf_get_prog_ctx_type()
4411 return btf_vmlinux; in bpf_prog_get_target_btf()
4613 tname = __btf_name_by_offset(btf_vmlinux, t->name_off); in btf_struct_walk()
4630 mtype = btf_type_skip_modifiers(btf_vmlinux, member->type, in btf_struct_walk()
4646 t = btf_type_skip_modifiers(btf_vmlinux, array_elem->type, in btf_struct_walk()
4704 mtype = btf_type_by_id(btf_vmlinux, member->type); in btf_struct_walk()
4705 mname = __btf_name_by_offset(btf_vmlinux, member->name_off); in btf_struct_walk()
4707 mtype = __btf_resolve_size(btf_vmlinux, mtype, &msize, in btf_struct_walk()
[all …]
Dverifier.c245 struct btf *btf_vmlinux; variable
561 return btf_name_by_offset(btf_vmlinux, in kernel_type_name()
562 btf_type_by_id(btf_vmlinux, id)->name_off); in kernel_type_name()
3296 const struct btf_type *t = btf_type_by_id(btf_vmlinux, reg->btf_id); in check_ptr_to_btf_access()
3297 const char *tname = btf_name_by_offset(btf_vmlinux, t->name_off); in check_ptr_to_btf_access()
3352 if (!btf_vmlinux) { in check_ptr_to_map_access()
3363 t = btf_type_by_id(btf_vmlinux, *map->ops->map_btf_id); in check_ptr_to_map_access()
3364 tname = btf_name_by_offset(btf_vmlinux, t->name_off); in check_ptr_to_map_access()
5155 t = btf_type_skip_modifiers(btf_vmlinux, meta.ret_btf_id, NULL); in check_helper_call()
5162 ret = btf_resolve_size(btf_vmlinux, t, &tsize); in check_helper_call()
[all …]
/Linux-v5.10/net/ipv4/
Dbpf_tcp_ca.c73 extern struct btf *btf_vmlinux;
214 if (!btf_type_resolve_func_ptr(btf_vmlinux, member->type, NULL)) in bpf_tcp_ca_init_member()
/Linux-v5.10/tools/lib/bpf/
Dlibbpf.c468 struct btf *btf_vmlinux; member
929 obj->btf_vmlinux); in bpf_object__init_kern_struct_ops_maps()
2551 obj->btf_vmlinux = libbpf_find_kernel_btf(); in bpf_object__load_vmlinux_btf()
2552 if (IS_ERR(obj->btf_vmlinux)) { in bpf_object__load_vmlinux_btf()
2553 err = PTR_ERR(obj->btf_vmlinux); in bpf_object__load_vmlinux_btf()
2555 obj->btf_vmlinux = NULL; in bpf_object__load_vmlinux_btf()
5850 targ_btf = obj->btf_vmlinux; in bpf_object__relocate_core()
5917 if (targ_btf != obj->btf_vmlinux) in bpf_object__relocate_core()
7115 id = btf__find_by_name_kind(obj->btf_vmlinux, ext->name, in bpf_object__resolve_ksyms_btf_id()
7127 targ_var = btf__type_by_id(obj->btf_vmlinux, id); in bpf_object__resolve_ksyms_btf_id()
[all …]