Home
last modified time | relevance | path

Searched refs:btf_type (Results 1 – 25 of 74) sorted by relevance

123

/linux-6.15/include/linux/
H A Dbtf.h113 struct btf_type;
230 bool btf_type_is_void(const struct btf_type *t);
239 const struct btf_type *
242 const char *btf_type_str(const struct btf_type *t);
291 const struct btf_type *t2) in btf_kind_core_compat()
302 static inline u16 btf_kind(const struct btf_type *t) in btf_kind()
307 static inline bool btf_is_enum(const struct btf_type *t) in btf_is_enum()
334 static inline bool btf_is_int(const struct btf_type *t) in btf_is_int()
339 static inline bool btf_is_ptr(const struct btf_type *t) in btf_is_ptr()
419 static inline u16 btf_vlen(const struct btf_type *t) in btf_vlen()
[all …]
H A Dbpf_local_storage.h177 const struct btf_type *key_type,
178 const struct btf_type *value_type);
/linux-6.15/tools/lib/bpf/
H A Dbtf.h26 struct btf_type;
177 const struct btf_type *src_type);
362 static inline __u16 btf_kind(const struct btf_type *t) in btf_kind()
367 static inline __u16 btf_vlen(const struct btf_type *t) in btf_vlen()
372 static inline bool btf_kflag(const struct btf_type *t) in btf_kflag()
382 static inline bool btf_is_int(const struct btf_type *t) in btf_is_int()
387 static inline bool btf_is_ptr(const struct btf_type *t) in btf_is_ptr()
424 static inline bool btf_is_fwd(const struct btf_type *t) in btf_is_fwd()
449 static inline bool btf_is_mod(const struct btf_type *t) in btf_is_mod()
500 const struct btf_type *t2) in btf_kind_core_compat()
[all …]
H A Dbtf_iter.c16 int btf_field_iter_init(struct btf_field_iter *it, struct btf_type *t, in btf_field_iter_init()
44 it->desc = (struct btf_field_desc) { 1, {offsetof(struct btf_type, type)} }; in btf_field_iter_init()
48 2, {sizeof(struct btf_type) + offsetof(struct btf_array, type), in btf_field_iter_init()
49 sizeof(struct btf_type) + offsetof(struct btf_array, index_type)} in btf_field_iter_init()
62 1, {offsetof(struct btf_type, type)}, in btf_field_iter_init()
98 1, {offsetof(struct btf_type, name_off)} in btf_field_iter_init()
103 1, {offsetof(struct btf_type, name_off)}, in btf_field_iter_init()
110 1, {offsetof(struct btf_type, name_off)}, in btf_field_iter_init()
118 1, {offsetof(struct btf_type, name_off)}, in btf_field_iter_init()
125 1, {offsetof(struct btf_type, name_off)}, in btf_field_iter_init()
[all …]
H A Dbtf_dump.c315 const struct btf_type *t; in btf_dump_mark_referenced()
484 const struct btf_type *t; in btf_dump_order_type()
690 const struct btf_type *t; in btf_dump_emit_type()
1292 const struct btf_type *t; in btf_dump_emit_type_decl()
1371 const struct btf_type *t; in btf_dump_emit_mods()
1397 const struct btf_type *t; in btf_dump_drop_mods()
1431 const struct btf_type *t; in btf_dump_emit_type_chain()
1608 const struct btf_type *t; in btf_dump_emit_type_cast()
2003 const struct btf_type *t; in btf_dump_var_data()
2243 const struct btf_type *var; in btf_dump_datasec_data()
[all …]
H A Dbtf.c1484 struct btf_type *t; in btf_get_raw_data()
1842 struct btf_type *t; in btf_add_type()
2013 struct btf_type *t; in btf__add_int()
2061 struct btf_type *t; in btf__add_float()
2106 struct btf_type *t; in btf_add_ref_kind()
2156 struct btf_type *t; in btf__add_array()
2186 struct btf_type *t; in btf_add_composite()
2266 struct btf_type *t; in btf__add_field()
2321 struct btf_type *t; in btf_add_enum_common()
2382 struct btf_type *t; in btf__add_enum_value()
[all …]
H A Drelo_core.c21 static const struct btf_type *
34 const struct btf_type *t; in btf__resolve_size()
75 const struct btf_type *t; in is_flex_arr()
269 const struct btf_type *t; in bpf_core_parse_spec()
561 const struct btf_type *targ_type; in bpf_core_spec_match()
685 const struct btf_type *t; in bpf_core_calc_field_relo()
688 const struct btf_type *mt; in bpf_core_calc_field_relo()
867 const struct btf_type *t; in bpf_core_calc_enumval_relo()
927 const struct btf_type *orig_t, *new_t; in bpf_core_calc_relo()
1174 const struct btf_type *t; in bpf_core_format_spec()
[all …]
H A Dbtf_relocate.c16 #define btf_type_by_id (struct btf_type *)btf_type_by_id
68 struct btf_type *t = btf_type_by_id(r->btf, i); in btf_relocate_rewrite_type_id()
134 struct btf_type *t = btf_type_by_id(r->btf, i); in btf_mark_embedded_composite_type_ids()
187 struct btf_type *base_t, *dist_t; in btf_relocate_map_distilled_base()
388 struct btf_type *t = btf_type_by_id(r->dist_base_btf, i); in btf_relocate_validate_distilled_base()
414 struct btf_type *t = btf_type_by_id(r->btf, i); in btf_relocate_rewrite_strs()
H A Dlibbpf_internal.h233 struct btf_type;
235 struct btf_type *btf_type_by_id(const struct btf *btf, __u32 type_id);
236 const char *btf_kind_str(const struct btf_type *t);
237 const struct btf_type *skip_mods_and_typedefs(const struct btf *btf, __u32 id, __u32 *res_id);
242 static inline enum btf_func_linkage btf_func_linkage(const struct btf_type *t) in btf_func_linkage()
283 const struct btf_type *def_t, bool strict,
566 int btf_field_iter_init(struct btf_field_iter *it, struct btf_type *t, enum btf_field_iter_kind ite…
/linux-6.15/tools/bpf/bpftool/
H A Dgen.c58 static const struct btf_type *
61 const struct btf_type *t; in resolve_func_ptr()
280 const struct btf_type *sec; in codegen_datasecs()
503 const struct btf_type *sec; in codegen_asserts()
2033 const struct btf_type *btf_type = btf__type_by_id(info->src_btf, type_id); in btfgen_mark_type() local
2108 const struct btf_type *btf_type; in btfgen_record_field_relo() local
2123 while (btf_is_mod(btf_type) || btf_is_typedef(btf_type)) { in btfgen_record_field_relo()
2124 type_id = btf_type->type; in btfgen_record_field_relo()
2151 btf_kind_str(btf_type), btf_type->type); in btfgen_record_field_relo()
2169 const struct btf_type *btf_type; in btfgen_mark_type_match() local
[all …]
H A Dbtf_dumper.c28 const struct btf_type *func_proto,
35 const struct btf_type *func_type; in dump_prog_id_as_func_ptr()
108 const struct btf_type *t, in btf_dumper_ptr()
112 const struct btf_type *ptr_type; in btf_dumper_ptr()
148 const struct btf_type *t, in btf_dumper_enum()
186 const struct btf_type *t, in btf_dumper_enum64()
214 const struct btf_type *elem_type; in is_str_array()
468 const struct btf_type *t; in btf_dumper_struct()
531 const struct btf_type *t; in btf_dumper_datasec()
622 const struct btf_type *proto_type; in __btf_dumper_type_only()
[all …]
H A Dbtf.c120 const struct btf_type *t) in dump_btf_type()
370 const struct btf_type *vt; in dump_btf_type()
438 const struct btf_type *t; in dump_btf_raw()
505 const struct btf_type *a = *(void **)pa; in cmp_kfuncs()
506 const struct btf_type *b = *(void **)pb; in cmp_kfuncs()
524 const struct btf_type *t = btf__type_by_id(btf, i); in dump_btf_kfuncs()
525 const struct btf_type *ft; in dump_btf_kfuncs()
555 const struct btf_type *t = kfuncs.elems[i]; in dump_btf_kfuncs()
591 const struct btf_type *t = btf__type_by_id(btf, index); in btf_type_rank()
676 const struct btf_type *t = btf__type_by_id(btf, id); in btf_type_disambig_hash()
[all …]
/linux-6.15/kernel/bpf/
H A Dbtf.c254 struct btf_type **types;
286 const struct btf_type *t;
548 const struct btf_type *t; in btf_find_by_name_kind()
630 const struct btf_type *t; in btf_type_resolve_ptr()
890 const struct btf_type *t; in btf_member_is_reg_int()
957 const struct btf_type *t; in btf_show_name()
1237 const struct btf_type *rt; in btf_show_obj_safe()
2003 const struct btf_type *
3406 const struct btf_type *t; in btf_find_decl_tag_value()
3786 const struct btf_type *t; in btf_parse_kptr()
[all …]
H A Dbpf_struct_ops.c90 const struct btf_type *type, in is_valid_value_type()
93 const struct btf_type *common_value_type; in is_valid_value_type()
95 const struct btf_type *vt, *mt; in is_valid_value_type()
312 const struct btf_type *t; in is_module_member()
338 const struct btf_type *t; in bpf_struct_ops_desc_init()
393 const struct btf_type *func_proto, *ret_type; in bpf_struct_ops_desc_init()
549 const struct btf_type *mtype; in check_zero_holes()
683 const struct btf_type *module_type; in bpf_struct_ops_map_update_elem()
685 const struct btf_type *t = st_ops_desc->type; in bpf_struct_ops_map_update_elem()
737 const struct btf_type *mtype, *ptype; in bpf_struct_ops_map_update_elem()
[all …]
H A Dinode.c600 const struct btf_type *cmd_t;
601 const struct btf_type *map_t;
602 const struct btf_type *prog_t;
603 const struct btf_type *attach_t;
609 const struct btf_type *t; in find_bpffs_btf_enums()
650 static bool find_btf_enum_const(const struct btf *btf, const struct btf_type *enum_t, in find_btf_enum_const()
682 const struct btf_type *enum_t, in seq_print_delegate_opts()
880 const struct btf_type *enum_t; in bpf_parse_param()
/linux-6.15/kernel/trace/
H A Dtrace_btf.h4 const struct btf_type *btf_find_func_proto(const char *func_name,
6 const struct btf_param *btf_get_func_param(const struct btf_type *func_proto,
9 const struct btf_type *type,
H A Dtrace_btf.c13 const struct btf_type *btf_find_func_proto(const char *func_name, struct btf **btf_p) in btf_find_func_proto()
15 const struct btf_type *t; in btf_find_func_proto()
43 const struct btf_param *btf_get_func_param(const struct btf_type *func_proto, s32 *nr) in btf_get_func_param()
71 const struct btf_type *type, in btf_find_struct_member()
/linux-6.15/net/bpf/
H A Dbpf_dummy_struct_ops.c98 const struct btf_type *func_proto = prog->aux->attach_func_proto; in check_test_run_args()
103 const struct btf_type *t; in check_test_run_args()
133 const struct btf_type *func_proto; in bpf_struct_ops_test_run()
218 static int bpf_dummy_ops_check_member(const struct btf_type *t, in bpf_dummy_ops_check_member()
239 const struct btf_type *state; in bpf_dummy_ops_btf_struct_access()
240 const struct btf_type *t; in bpf_dummy_ops_btf_struct_access()
268 static int bpf_dummy_init_member(const struct btf_type *t, in bpf_dummy_init_member()
/linux-6.15/tools/testing/selftests/bpf/prog_tests/
H A Dlibbpf_str.c24 const struct btf_type *t; in test_libbpf_bpf_attach_type_str()
69 const struct btf_type *t; in test_libbpf_bpf_link_type_str()
114 const struct btf_type *t; in test_libbpf_bpf_map_type_str()
171 const struct btf_type *t; in test_libbpf_bpf_prog_type_str()
H A Dtest_global_funcs.c28 const struct btf_type *t; in check_ctx_arg_type()
93 const struct btf_type *fn_t, *proto_t; in subtest_ctx_arg_rewrite()
H A Dlibbpf_probes.c10 const struct btf_type *t; in test_libbpf_probe_prog_types()
50 const struct btf_type *t; in test_libbpf_probe_map_types()
/linux-6.15/Documentation/bpf/
H A Dbtf.rst97 struct btf_type {
129 ``struct btf_type`` encoding requirement:
181 ``struct btf_type`` encoding requirement:
193 ``struct btf_type`` encoding requirement:
238 ``struct btf_type`` encoding requirement:
282 ``struct btf_type`` encoding requirement:
307 ``struct btf_type`` encoding requirement:
319 ``struct btf_type`` encoding requirement:
331 ``struct btf_type`` encoding requirement:
343 ``struct btf_type`` encoding requirement:
[all …]
/linux-6.15/kernel/bpf/preload/iterators/
H A Diterators.bpf.c26 struct btf_type { struct
36 struct btf_type **types; argument
61 struct btf_type **types, *t; in get_name()
/linux-6.15/net/ipv4/
H A Dbpf_tcp_ca.c17 static const struct btf_type *tcp_sock_type;
19 static const struct btf_type *tcp_congestion_ops_type;
65 const struct btf_type *t; in bpf_tcp_ca_btf_struct_access()
141 const struct btf_type *t; in prog_ops_moff()
210 static int bpf_tcp_ca_init_member(const struct btf_type *t, in bpf_tcp_ca_init_member()
/linux-6.15/drivers/hid/bpf/
H A Dhid_bpf_struct_ops.c39 static int hid_bpf_ops_check_member(const struct btf_type *t, in hid_bpf_ops_check_member()
84 const struct btf_type *state = NULL; in hid_bpf_ops_btf_struct_access()
85 const struct btf_type *t; in hid_bpf_ops_btf_struct_access()
149 static int hid_bpf_ops_init_member(const struct btf_type *t, in hid_bpf_ops_init_member()

123