Home
last modified time | relevance | path

Searched refs:insns_cnt (Results 1 – 15 of 15) sorted by relevance

/linux-6.6.21/samples/bpf/
Dtest_cgrp2_sock.c79 size_t insns_cnt; in prog_load() local
83 insns_cnt = sizeof(prog_start) + sizeof(prog_end); in prog_load()
85 insns_cnt += sizeof(prog_dev); in prog_load()
88 insns_cnt += sizeof(prog_mark); in prog_load()
91 insns_cnt += sizeof(prog_prio); in prog_load()
93 p = prog = malloc(insns_cnt); in prog_load()
120 insns_cnt /= sizeof(struct bpf_insn); in prog_load()
123 prog, insns_cnt, &opts); in prog_load()
Dsock_example.c62 size_t insns_cnt = ARRAY_SIZE(prog); in test_sock() local
69 prog, insns_cnt, &opts); in test_sock()
Dtest_cgrp2_attach.c74 size_t insns_cnt = ARRAY_SIZE(prog); in prog_load() local
81 prog, insns_cnt, &opts); in prog_load()
Dfds_example.c56 size_t insns_cnt = ARRAY_SIZE(insns); in bpf_prog_create() local
73 insns, insns_cnt, &opts); in bpf_prog_create()
/linux-6.6.21/tools/testing/selftests/bpf/prog_tests/
Dcgroup_attach_autodetach.c17 size_t insns_cnt = ARRAY_SIZE(prog); in prog_load() local
20 prog, insns_cnt, "GPL", 0, in prog_load()
Dcgroup_attach_override.c19 size_t insns_cnt = ARRAY_SIZE(prog); in prog_load() local
22 prog, insns_cnt, "GPL", 0, in prog_load()
Dsockopt.c928 int fd, insns_cnt = 0; in load_prog() local
931 insns[insns_cnt].code != (BPF_JMP | BPF_EXIT); in load_prog()
932 insns_cnt++) { in load_prog()
934 insns_cnt++; in load_prog()
936 fd = bpf_prog_load(BPF_PROG_TYPE_CGROUP_SOCKOPT, NULL, "GPL", insns, insns_cnt, &opts); in load_prog()
Dcgroup_attach_multi.c66 size_t insns_cnt = ARRAY_SIZE(prog); in prog_load_cnt() local
70 prog, insns_cnt, "GPL", 0, in prog_load_cnt()
/linux-6.6.21/tools/testing/selftests/bpf/
Dtest_cgroup_storage.c39 size_t insns_cnt = ARRAY_SIZE(prog); in main() local
74 prog, insns_cnt, "GPL", 0, in main()
Dtesting_helpers.h17 size_t insns_cnt, const char *license,
Dtesting_helpers.c296 size_t insns_cnt, const char *license, in bpf_test_load_program() argument
308 return bpf_prog_load(type, NULL, license, insns, insns_cnt, &opts); in bpf_test_load_program()
Dtest_sock_addr.c645 const struct bpf_insn *insns, size_t insns_cnt) in load_insns() argument
654 ret = bpf_prog_load(BPF_PROG_TYPE_CGROUP_SOCK_ADDR, NULL, "GPL", insns, insns_cnt, &opts); in load_insns()
/linux-6.6.21/tools/lib/bpf/
Dlibbpf_probes.c104 const struct bpf_insn *insns, size_t insns_cnt, in probe_prog_load() argument
191 fd = bpf_prog_load(prog_type, NULL, "GPL", insns, insns_cnt, &opts); in probe_prog_load()
Dlibbpf.c424 size_t insns_cnt; member
722 prog->insns_cnt = 0; in bpf_program__exit()
764 prog->insns_cnt = prog->sec_insn_cnt; in bpf_object__init_prog()
5853 if (insn_idx >= prog->insns_cnt) in bpf_object__relocate_core()
6321 subprog->sub_insn_off = main_prog->insns_cnt; in bpf_object__reloc_code()
6323 new_cnt = main_prog->insns_cnt + subprog->insns_cnt; in bpf_object__reloc_code()
6330 main_prog->insns_cnt = new_cnt; in bpf_object__reloc_code()
6333 subprog->insns_cnt * sizeof(*insns)); in bpf_object__reloc_code()
6336 main_prog->name, subprog->insns_cnt, subprog->name); in bpf_object__reloc_code()
6790 for (i = 0; i < prog->insns_cnt; i++, insn++) { in bpf_object__sanitize_prog()
[all …]
/linux-6.6.21/tools/bpf/bpftool/
Dfeature.c518 const struct bpf_insn *insns, size_t insns_cnt, in probe_prog_load_ifindex() argument
531 fd = bpf_prog_load(prog_type, NULL, "GPL", insns, insns_cnt, &opts); in probe_prog_load_ifindex()