Home
last modified time | relevance | path

Searched refs:type_id (Results 1 – 25 of 68) sorted by relevance

123

/Linux-v5.15/tools/bpf/bpftool/Documentation/
Dbpftool-btf.rst97 [1] PTR '(anon)' type_id=2
99 'pad' type_id=3 bits_offset=0
100 'sock' type_id=4 bits_offset=64
102 [4] PTR '(anon)' type_id=5
152 [1] PTR '(anon)' type_id=2
154 'a' type_id=3 bits_offset=0
155 'b' type_id=4 bits_offset=0
158 'const_int_field' type_id=5 bits_offset=0
159 'bitfield_field' type_id=3 bits_offset=32 bitfield_size=4
160 'arr_field' type_id=8 bits_offset=40
[all …]
/Linux-v5.15/tools/testing/selftests/bpf/prog_tests/
Dresolve_btfids.c66 __resolve_symbol(struct btf *btf, int type_id) in BTF_ID_LIST_GLOBAL()
72 type = btf__type_by_id(btf, type_id); in BTF_ID_LIST_GLOBAL()
74 PRINT_FAIL("Failed to get type for ID %d\n", type_id); in BTF_ID_LIST_GLOBAL()
87 PRINT_FAIL("Failed to get name for BTF ID %d\n", type_id); in BTF_ID_LIST_GLOBAL()
92 test_symbols[i].id = type_id; in BTF_ID_LIST_GLOBAL()
101 int type_id; in resolve_symbols() local
111 for (type_id = 1; type_id <= nr; type_id++) { in resolve_symbols()
112 if (__resolve_symbol(btf, type_id)) in resolve_symbols()
Dbtf_dump.c252 __s32 type_id; in btf_dump_data() local
266 type_id = btf__find_by_name(btf, name); in btf_dump_data()
267 if (!ASSERT_GE(type_id, 0, "find type id")) in btf_dump_data()
269 type_sz = btf__resolve_size(btf, type_id); in btf_dump_data()
271 ret = btf_dump__dump_type_data(d, type_id, ptr, ptr_sz, &opts); in btf_dump_data()
537 __s32 type_id; in test_btf_dump_struct_data() local
607 type_id = btf__find_by_name(btf, "file_operations"); in test_btf_dump_struct_data()
608 if (ASSERT_GT(type_id, 0, "find type id")) { in test_btf_dump_struct_data()
609 type_sz = btf__resolve_size(btf, type_id); in test_btf_dump_struct_data()
612 ret = btf_dump__dump_type_data(d, type_id, fops, type_sz, &opts); in test_btf_dump_struct_data()
[all …]
Dbtf_module.c13 __s32 type_id; in test_btf_module() local
28 type_id = btf__find_by_name(module_btf, symbol_name); in test_btf_module()
29 ASSERT_GT(type_id, 0, "func not found"); in test_btf_module()
/Linux-v5.15/tools/bpf/bpftool/
Dbtf_dumper.c24 static int btf_dumper_do_type(const struct btf_dumper *d, __u32 type_id,
73 func_type = btf__type_by_id(prog_btf, finfo->type_id); in dump_prog_id_as_func_ptr()
127 static int btf_dumper_modifier(const struct btf_dumper *d, __u32 type_id, in btf_dumper_modifier() argument
132 actual_type_id = btf__resolve_type(d->btf, type_id); in btf_dumper_modifier()
213 static int btf_dumper_array(const struct btf_dumper *d, __u32 type_id, in btf_dumper_array() argument
216 const struct btf_type *t = btf__type_by_id(d->btf, type_id); in btf_dumper_array()
431 static int btf_dumper_struct(const struct btf_dumper *d, __u32 type_id, in btf_dumper_struct() argument
441 t = btf__type_by_id(d->btf, type_id); in btf_dumper_struct()
479 static int btf_dumper_var(const struct btf_dumper *d, __u32 type_id, in btf_dumper_var() argument
482 const struct btf_type *t = btf__type_by_id(d->btf, type_id); in btf_dumper_var()
[all …]
/Linux-v5.15/drivers/media/usb/pwc/
Dpwc-if.c778 int vendor_id, product_id, type_id; in usb_pwc_probe() local
805 type_id = 645; in usb_pwc_probe()
810 type_id = 646; in usb_pwc_probe()
815 type_id = 646; in usb_pwc_probe()
820 type_id = 675; in usb_pwc_probe()
825 type_id = 680; in usb_pwc_probe()
830 type_id = 690; in usb_pwc_probe()
835 type_id = 730; in usb_pwc_probe()
840 type_id = 740; in usb_pwc_probe()
845 type_id = 750; in usb_pwc_probe()
[all …]
/Linux-v5.15/tools/lib/bpf/
Dbtf.c434 struct btf_type *btf_type_by_id(struct btf *btf, __u32 type_id) in btf_type_by_id() argument
436 if (type_id == 0) in btf_type_by_id()
438 if (type_id < btf->start_id) in btf_type_by_id()
439 return btf_type_by_id(btf->base_btf, type_id); in btf_type_by_id()
440 return btf->types_data + btf->type_offs[type_id - btf->start_id]; in btf_type_by_id()
443 const struct btf_type *btf__type_by_id(const struct btf *btf, __u32 type_id) in btf__type_by_id() argument
445 if (type_id >= btf->start_id + btf->nr_types) in btf__type_by_id()
447 return btf_type_by_id((struct btf *)btf, type_id); in btf__type_by_id()
562 __s64 btf__resolve_size(const struct btf *btf, __u32 type_id) in btf__resolve_size() argument
570 t = btf__type_by_id(btf, type_id); in btf__resolve_size()
[all …]
Drelo_core.c20 __u32 type_id; /* struct/union type or array element type */ member
54 t = btf__type_by_id(btf, acc->type_id); in is_flex_arr()
154 __u32 type_id, in bpf_core_parse_spec() argument
171 spec->root_type_id = type_id; in bpf_core_parse_spec()
196 t = skip_mods_and_typedefs(btf, type_id, &id); in bpf_core_parse_spec()
202 acc->type_id = id; in bpf_core_parse_spec()
247 acc->type_id = id; in bpf_core_parse_spec()
266 spec->spec[spec->len].type_id = id; in bpf_core_parse_spec()
276 type_id, spec_str, i, id, btf_kind_str(t)); in bpf_core_parse_spec()
390 local_id = local_acc->type_id; in bpf_core_match_member()
[all …]
Dbtf.h70 LIBBPF_API __s64 btf__resolve_size(const struct btf *btf, __u32 type_id);
71 LIBBPF_API int btf__resolve_type(const struct btf *btf, __u32 type_id);
136 LIBBPF_API int btf__add_func_param(struct btf *btf, const char *name, int type_id);
139 LIBBPF_API int btf__add_var(struct btf *btf, const char *name, int linkage, int type_id);
Drelo_core.h73 __u32 type_id; member
/Linux-v5.15/drivers/hid/usbhid/
Dhid-pidff.c182 int type_id[sizeof(pidff_effect_types)]; member
556 int type_id; in pidff_upload_effect() local
569 pidff->type_id[PID_CONSTANT]); in pidff_upload_effect()
588 type_id = PID_SQUARE; in pidff_upload_effect()
591 type_id = PID_TRIANGLE; in pidff_upload_effect()
594 type_id = PID_SINE; in pidff_upload_effect()
597 type_id = PID_SAW_UP; in pidff_upload_effect()
600 type_id = PID_SAW_DOWN; in pidff_upload_effect()
608 pidff->type_id[type_id]); in pidff_upload_effect()
626 pidff->type_id[PID_RAMP]); in pidff_upload_effect()
[all …]
/Linux-v5.15/kernel/bpf/
Dbtf.c178 #define BTF_TYPE_ID_VALID(type_id) ((type_id) <= BTF_MAX_TYPE) argument
230 u32 type_id; member
362 u32 type_id; member
393 u32 type_id, void *data, u8 bits_offsets,
401 const struct btf_type *t, u32 type_id);
709 const struct btf_type *btf_type_by_id(const struct btf *btf, u32 type_id) in btf_type_by_id() argument
711 while (type_id < btf->start_id) in btf_type_by_id()
714 type_id -= btf->start_id; in btf_type_by_id()
715 if (type_id >= btf->nr_types) in btf_type_by_id()
717 return btf->types[type_id]; in btf_type_by_id()
[all …]
Dbpf_struct_ops.c102 s32 type_id, value_id, module_id; in bpf_struct_ops_init() local
141 type_id = btf_find_by_name_kind(btf, st_ops->name, in bpf_struct_ops_init()
143 if (type_id < 0) { in bpf_struct_ops_init()
148 t = btf_type_by_id(btf, type_id); in bpf_struct_ops_init()
189 st_ops->type_id = type_id; in bpf_struct_ops_init()
217 const struct bpf_struct_ops *bpf_struct_ops_find(u32 type_id) in bpf_struct_ops_find() argument
221 if (!type_id || !btf_vmlinux) in bpf_struct_ops_find()
225 if (bpf_struct_ops[i]->type_id == type_id) in bpf_struct_ops_find()
427 prog->aux->attach_btf_id != st_ops->type_id || in bpf_struct_ops_map_update_elem()
/Linux-v5.15/arch/x86/events/intel/
Duncore_discovery.c67 const u16 *type_id = key; in __type_cmp() local
69 if (type_b->type > *type_id) in __type_cmp()
71 else if (type_b->type < *type_id) in __type_cmp()
78 search_uncore_discovery_type(u16 type_id) in search_uncore_discovery_type() argument
80 struct rb_node *node = rb_find(&type_id, &discovery_tables, __type_cmp); in search_uncore_discovery_type()
465 type->type_id, type->box_ids[box->pmu->pmu_idx]); in intel_generic_uncore_mmio_init_box()
473 type->type_id, type->box_ids[box->pmu->pmu_idx], in intel_generic_uncore_mmio_init_box()
529 static bool uncore_update_uncore_type(enum uncore_access_type type_id, in uncore_update_uncore_type() argument
533 uncore->type_id = type->type; in uncore_update_uncore_type()
539 switch (type_id) { in uncore_update_uncore_type()
[all …]
/Linux-v5.15/include/linux/
Dbtf.h51 u32 *type_id,
71 void btf_type_seq_show(const struct btf *btf, u32 type_id, void *obj,
73 int btf_type_seq_show_flags(const struct btf *btf, u32 type_id, void *obj,
89 int btf_type_snprintf_show(const struct btf *btf, u32 type_id, void *obj,
224 const struct btf_type *btf_type_by_id(const struct btf *btf, u32 type_id);
230 u32 type_id) in btf_type_by_id() argument
/Linux-v5.15/net/ipv4/
Dbpf_tcp_ca.c37 s32 type_id; in bpf_tcp_ca_init() local
39 type_id = btf_find_by_name_kind(btf, "sock", BTF_KIND_STRUCT); in bpf_tcp_ca_init()
40 if (type_id < 0) in bpf_tcp_ca_init()
42 sock_id = type_id; in bpf_tcp_ca_init()
44 type_id = btf_find_by_name_kind(btf, "tcp_sock", BTF_KIND_STRUCT); in bpf_tcp_ca_init()
45 if (type_id < 0) in bpf_tcp_ca_init()
47 tcp_sock_id = type_id; in bpf_tcp_ca_init()
/Linux-v5.15/drivers/media/pci/cx88/
Dcx88-mpeg.c504 if (d->type_id == btype) in cx8802_get_driver()
519 core->active_type_id != drv->type_id) in cx8802_request_acquire()
522 if (drv->type_id == CX88_MPEG_DVB) { in cx8802_request_acquire()
539 core->active_type_id = drv->type_id; in cx8802_request_acquire()
555 if (drv->type_id == CX88_MPEG_DVB) { in cx8802_request_release()
576 if ((drv->type_id != CX88_MPEG_DVB) && in cx8802_check_driver()
577 (drv->type_id != CX88_MPEG_BLACKBIRD)) in cx8802_check_driver()
600 drv->type_id == CX88_MPEG_DVB ? "dvb" : "blackbird", in cx8802_register_driver()
658 drv->type_id == CX88_MPEG_DVB ? "dvb" : "blackbird", in cx8802_unregister_driver()
674 if (d->type_id != drv->type_id) in cx8802_unregister_driver()
/Linux-v5.15/tools/bpf/resolve_btfids/
Dmain.c480 int err, type_id; in symbols_resolve() local
498 for (type_id = 1; type_id <= nr_types; type_id++) { in symbols_resolve()
505 type = btf__type_by_id(btf, type_id); in symbols_resolve()
508 type_id); in symbols_resolve()
530 type_id); in symbols_resolve()
538 str, id->id, type_id, id->id); in symbols_resolve()
540 id->id = type_id; in symbols_resolve()
/Linux-v5.15/drivers/net/ethernet/hisilicon/hns3/hns3pf/
Dhclge_err.c1280 .type_id = NONE_ERROR,
1283 .type_id = FIFO_ERROR,
1286 .type_id = MEMORY_ERROR,
1289 .type_id = POISON_ERROR,
1292 .type_id = MSIX_ECC_ERROR,
1295 .type_id = TQP_INT_ECC_ERROR,
1298 .type_id = PF_ABNORMAL_INT_ERROR,
1301 .type_id = MPF_ABNORMAL_INT_ERROR,
1304 .type_id = COMMON_ERROR,
1307 .type_id = PORT_ERROR,
[all …]
Dhclge_err.h193 enum hclge_err_type_list type_id; member
210 u8 type_id; member
/Linux-v5.15/tools/testing/selftests/bpf/progs/
Dnetif_receive_skb.c67 _ptr.type_id = bpf_core_type_id_kernel(_type); \
68 if (_ptr.type_id <= 0) { \
112 p.type_id = bpf_core_type_id_kernel(struct sk_buff); in BPF_PROG()
Dbtf_ptr.h18 __u32 type_id; member
Dbpf_iter_task_btf.c24 ptr.type_id = bpf_core_type_id_kernel(struct task_struct); in dump_task_struct()
/Linux-v5.15/tools/testing/selftests/bpf/
Dbtf_helpers.h10 const char *btf_type_raw_dump(const struct btf *btf, int type_id);
Dbtf_helpers.c190 const char *btf_type_raw_dump(const struct btf *btf, int type_id) in btf_type_raw_dump() argument
201 fprintf_btf_type_raw(buf_file, btf, type_id); in btf_type_raw_dump()

123