Home
last modified time | relevance | path

Searched refs:prog_ids (Results 1 – 21 of 21) sorted by relevance

/linux-6.3-rc2/tools/testing/selftests/bpf/prog_tests/
A Dcgroup_attach_multi.c79 __u32 prog_ids[4], prog_cnt = 0, attach_flags, saved_prog_id; in serial_test_cgroup_attach_multi() local
161 prog_ids, &prog_cnt)); in serial_test_cgroup_attach_multi()
164 saved_prog_id = prog_ids[0]; in serial_test_cgroup_attach_multi()
166 prog_ids[0] = 0; in serial_test_cgroup_attach_multi()
170 prog_ids, &prog_cnt) >= 0); in serial_test_cgroup_attach_multi()
174 CHECK_FAIL(prog_ids[0] != saved_prog_id); in serial_test_cgroup_attach_multi()
176 prog_ids[0] = 0; in serial_test_cgroup_attach_multi()
178 prog_ids, &prog_cnt)); in serial_test_cgroup_attach_multi()
180 CHECK_FAIL(prog_ids[0] != saved_prog_id); in serial_test_cgroup_attach_multi()
275 prog_ids, &prog_cnt)); in serial_test_cgroup_attach_multi()
[all …]
A Dcgroup_attach_autodetach.c28 __u32 prog_ids[2] = {0}; in serial_test_cgroup_attach_autodetach() local
60 prog_ids, &prog_cnt), in serial_test_cgroup_attach_autodetach()
86 for (i = 0; i < ARRAY_SIZE(prog_ids); i++) { in serial_test_cgroup_attach_autodetach()
88 int fd = bpf_prog_get_fd_by_id(prog_ids[i]); in serial_test_cgroup_attach_autodetach()
A Dcgroup_link.c41 __u32 prog_ids[ARRAY_SIZE(cgs)], prog_cnt = 0, attach_flags, prog_id; in serial_test_cgroup_link() local
93 BPF_F_QUERY_EFFECTIVE, NULL, prog_ids, in serial_test_cgroup_link()
100 CHECK(prog_ids[i - 1] != prog_ids[i], "prog_id_check", in serial_test_cgroup_link()
102 i, prog_ids[i - 1], prog_ids[i]); in serial_test_cgroup_link()
A Dsockmap_basic.c315 __u32 prog_ids[3] = {}; in test_sockmap_progs_query() local
330 &attach_flags, prog_ids, &prog_cnt); in test_sockmap_progs_query()
341 &attach_flags, prog_ids, &prog_cnt); in test_sockmap_progs_query()
345 ASSERT_EQ(prog_ids[0], query_prog_id(verdict_fd), in test_sockmap_progs_query()
A Dlsm_cgroup.c39 p.prog_ids = malloc(sizeof(u32) * p.prog_cnt); in query_prog_cnt()
48 fd = bpf_prog_get_fd_by_id(p.prog_ids[i]); in query_prog_cnt()
59 free(p.prog_ids); in query_prog_cnt()
A Dsk_lookup.c520 __u32 prog_ids[3] = {}; in query_lookup_prog() local
543 &attach_flags, prog_ids, &prog_cnt); in query_lookup_prog()
557 CHECK(prog_ids[0] != prog_id, "bpf_prog_query", in query_lookup_prog()
559 prog_ids[0], prog_id); in query_lookup_prog()
563 CHECK(prog_ids[1] != prog_id, "bpf_prog_query", in query_lookup_prog()
565 prog_ids[1], prog_id); in query_lookup_prog()
569 CHECK(prog_ids[2] != prog_id, "bpf_prog_query", in query_lookup_prog()
571 prog_ids[2], prog_id); in query_lookup_prog()
581 CHECK(prog_ids[0] != prog_id, "bpf_prog_query", in query_lookup_prog()
583 prog_ids[0], prog_id); in query_lookup_prog()
A Dflow_dissector_reattach.c23 __u32 prog_ids[1] = {}; in query_attached_prog_id() local
24 __u32 prog_cnt = ARRAY_SIZE(prog_ids); in query_attached_prog_id()
28 prog_ids, &prog_cnt); in query_attached_prog_id()
34 return prog_cnt == 1 ? prog_ids[0] : 0; in query_attached_prog_id()
A Dunpriv_bpf_disabled.c157 __u32 prog_ids[3] = {}; in test_unpriv_bpf_disabled_negative() local
199 ASSERT_EQ(bpf_prog_query(prog_fd, BPF_TRACE_FENTRY, 0, &attach_flags, prog_ids, in test_unpriv_bpf_disabled_negative()
/linux-6.3-rc2/tools/bpf/bpftool/
A Dcgroup.c206 __u32 prog_ids[1024] = {0}; in show_effective_bpf_progs() local
211 p.prog_cnt = ARRAY_SIZE(prog_ids); in show_effective_bpf_progs()
212 p.prog_ids = prog_ids; in show_effective_bpf_progs()
222 show_bpf_prog(prog_ids[iter], type, NULL, level); in show_effective_bpf_progs()
233 __u32 prog_ids[1024] = {0}; in show_attached_bpf_progs() local
239 p.prog_cnt = ARRAY_SIZE(prog_ids); in show_attached_bpf_progs()
240 p.prog_ids = prog_ids; in show_attached_bpf_progs()
270 show_bpf_prog(prog_ids[iter], type, in show_attached_bpf_progs()
A Dnet.c489 __u32 prog_ids[1]; in query_flow_dissector() local
500 prog_cnt = ARRAY_SIZE(prog_ids); in query_flow_dissector()
502 &attach_flags, prog_ids, &prog_cnt); in query_flow_dissector()
517 attach_info->flow_dissector_id = prog_ids[0]; in query_flow_dissector()
/linux-6.3-rc2/tools/testing/selftests/bpf/
A Dtest_lirc_mode2_user.c55 u32 prog_ids[10], prog_flags[10], prog_cnt; in main() local
89 ret = bpf_prog_query(lircfd, BPF_LIRC_MODE2, 0, prog_flags, prog_ids, in main()
157 ret = bpf_prog_query(lircfd, BPF_LIRC_MODE2, 0, prog_flags, prog_ids, in main()
/linux-6.3-rc2/drivers/media/rc/
A Dbpf-lirc.c297 __u32 __user *prog_ids = u64_to_user_ptr(attr->query.prog_ids); in lirc_prog_query() local
332 if (attr->query.prog_cnt != 0 && prog_ids && cnt) in lirc_prog_query()
333 ret = bpf_prog_array_copy_to_user(progs, prog_ids, in lirc_prog_query()
/linux-6.3-rc2/kernel/bpf/
A Dnet_namespace.c251 __u32 __user *prog_ids = u64_to_user_ptr(attr->query.prog_ids); in __netns_bpf_prog_query() local
264 if (!attr->query.prog_cnt || !prog_ids || !prog_cnt) in __netns_bpf_prog_query()
267 return bpf_prog_array_copy_to_user(run_array, prog_ids, in __netns_bpf_prog_query()
A Dcgroup.c1024 __u32 __user *prog_ids = u64_to_user_ptr(attr->query.prog_ids); in __cgroup_bpf_query() local
1038 prog_ids && !prog_attach_flags) in __cgroup_bpf_query()
1068 if (attr->query.prog_cnt == 0 || !prog_ids || !total_cnt) in __cgroup_bpf_query()
1082 ret = bpf_prog_array_copy_to_user(effective, prog_ids, cnt); in __cgroup_bpf_query()
1095 if (copy_to_user(prog_ids + i, &id, sizeof(id))) in __cgroup_bpf_query()
1112 prog_ids += cnt; in __cgroup_bpf_query()
A Dcore.c2304 u32 *prog_ids, in bpf_prog_array_copy_core() argument
2313 prog_ids[i] = item->prog->aux->id; in bpf_prog_array_copy_core()
2324 __u32 __user *prog_ids, u32 cnt) in bpf_prog_array_copy_to_user() argument
2340 err = copy_to_user(prog_ids, ids, cnt * sizeof(u32)); in bpf_prog_array_copy_to_user()
2488 u32 *prog_ids, u32 request_cnt, in bpf_prog_array_copy_info() argument
2503 return bpf_prog_array_copy_core(array, prog_ids, request_cnt) ? -ENOSPC in bpf_prog_array_copy_info()
/linux-6.3-rc2/tools/lib/bpf/
A Dbpf.h403 __u32 *prog_ids; member
414 __u32 *prog_ids, __u32 *prog_cnt);
A Dbpf.c837 attr.query.prog_ids = ptr_to_u64(OPTS_GET(opts, prog_ids, NULL)); in bpf_prog_query_opts()
849 __u32 *attach_flags, __u32 *prog_ids, __u32 *prog_cnt) in bpf_prog_query() argument
855 opts.prog_ids = prog_ids; in bpf_prog_query()
/linux-6.3-rc2/net/core/
A Dsock_map.c1491 __u32 __user *prog_ids = u64_to_user_ptr(attr->query.prog_ids); in sock_map_bpf_prog_query() local
1517 if (!attr->query.prog_cnt || !prog_ids || !prog_cnt) in sock_map_bpf_prog_query()
1531 (id != 0 && copy_to_user(prog_ids, &id, sizeof(u32))) || in sock_map_bpf_prog_query()
/linux-6.3-rc2/include/linux/
A Dbpf.h1693 __u32 __user *prog_ids, u32 cnt);
1701 u32 *prog_ids, u32 request_cnt,
/linux-6.3-rc2/include/uapi/linux/
A Dbpf.h1472 __aligned_u64 prog_ids; member
/linux-6.3-rc2/tools/include/uapi/linux/
A Dbpf.h1472 __aligned_u64 prog_ids; member

Completed in 72 milliseconds