Home
last modified time | relevance | path

Searched refs:bpf_prog_attach (Results 1 – 18 of 18) sorted by relevance

/Linux-v4.19/samples/bpf/
Dtest_cgrp2_attach2.c86 if (bpf_prog_attach(drop_prog, foo, BPF_CGROUP_INET_EGRESS, in test_foo_bar()
106 if (bpf_prog_attach(allow_prog, bar, BPF_CGROUP_INET_EGRESS, in test_foo_bar()
124 if (bpf_prog_attach(allow_prog, bar, BPF_CGROUP_INET_EGRESS, in test_foo_bar()
139 if (bpf_prog_attach(allow_prog, bar, BPF_CGROUP_INET_EGRESS, in test_foo_bar()
145 if (!bpf_prog_attach(allow_prog, bar, BPF_CGROUP_INET_EGRESS, 0)) { in test_foo_bar()
162 if (bpf_prog_attach(allow_prog, foo, BPF_CGROUP_INET_EGRESS, 0)) { in test_foo_bar()
167 if (!bpf_prog_attach(allow_prog, bar, BPF_CGROUP_INET_EGRESS, 0)) { in test_foo_bar()
173 if (!bpf_prog_attach(allow_prog, bar, BPF_CGROUP_INET_EGRESS, in test_foo_bar()
180 if (!bpf_prog_attach(allow_prog, foo, BPF_CGROUP_INET_EGRESS, in test_foo_bar()
187 if (bpf_prog_attach(drop_prog, foo, BPF_CGROUP_INET_EGRESS, 0)) { in test_foo_bar()
[all …]
Dtest_cgrp2_sock2.c59 ret = bpf_prog_attach(prog_fd[filter_id], cg_fd, in main()
Dload_sock_ops.c87 error = bpf_prog_attach(prog_fd[0], cg_fd, BPF_CGROUP_SOCK_OPS, 0); in main()
Dtest_cgrp2_attach.c108 ret = bpf_prog_attach(prog_fd, cg_fd, type, 0); in attach_filter()
Dtest_cgrp2_sock.c272 ret = bpf_prog_attach(prog_fd, cg_fd, in main()
/Linux-v4.19/tools/testing/selftests/bpf/
Dtest_maps.c595 err = bpf_prog_attach(-1, fd, BPF_SK_SKB_STREAM_PARSER, 0); in test_sockmap()
601 err = bpf_prog_attach(-1, fd, BPF_SK_SKB_STREAM_VERDICT, 0); in test_sockmap()
607 err = bpf_prog_attach(-1, fd, BPF_SK_MSG_VERDICT, 0); in test_sockmap()
613 err = bpf_prog_attach(-1, fd, __MAX_BPF_ATTACH_TYPE, 0); in test_sockmap()
713 err = bpf_prog_attach(parse_prog, map_fd_break, in test_sockmap()
720 err = bpf_prog_attach(parse_prog, map_fd_rx, in test_sockmap()
727 err = bpf_prog_attach(verdict_prog, map_fd_rx, in test_sockmap()
734 err = bpf_prog_attach(msg_prog, map_fd_msg, BPF_SK_MSG_VERDICT, 0); in test_sockmap()
740 err = bpf_prog_attach(verdict_prog, map_fd_rx, in test_sockmap()
861 err = bpf_prog_attach(parse_prog, fd, in test_sockmap()
[all …]
Dtest_dev_cgroup.c57 if (bpf_prog_attach(prog_fd, cgroup_fd, BPF_CGROUP_DEVICE, 0)) { in main()
Dtest_lirc_mode2_user.c98 ret = bpf_prog_attach(progfd, lircfd, BPF_LIRC_MODE2, 0); in main()
Dtest_cgroup_storage.c69 if (bpf_prog_attach(prog_fd, cgroup_fd, BPF_CGROUP_INET_EGRESS, 0)) { in main()
Dtest_tcpbpf_user.c97 rv = bpf_prog_attach(prog_fd, cg_fd, BPF_CGROUP_SOCK_OPS, 0); in main()
Dtest_socket_cookie.c170 err = bpf_prog_attach(bpf_program__fd(prog), cgfd, attach_type, in run_test()
Dtest_sockmap.c629 err = bpf_prog_attach(prog_fd[0], map_fd[0], in run_options()
638 err = bpf_prog_attach(prog_fd[1], map_fd[0], in run_options()
647 err = bpf_prog_attach(prog_fd[2], cg_fd, BPF_CGROUP_SOCK_OPS, 0); in run_options()
683 err = bpf_prog_attach(tx_prog_fd, in run_options()
Dtest_sock.c342 return bpf_prog_attach(progfd, cgfd, attach_type, BPF_F_ALLOW_OVERRIDE); in attach_sock_prog()
Dtest_sock_addr.c1295 err = bpf_prog_attach(progfd, cgfd, test->attach_type, in run_test_case()
/Linux-v4.19/tools/lib/bpf/
Dbpf.h93 int bpf_prog_attach(int prog_fd, int attachable_fd, enum bpf_attach_type type,
Dbpf.c333 int bpf_prog_attach(int prog_fd, int target_fd, enum bpf_attach_type type, in bpf_prog_attach() function
/Linux-v4.19/tools/bpf/bpftool/
Dcgroup.c375 if (bpf_prog_attach(prog_fd, cgroup_fd, attach_type, attach_flags)) { in do_attach()
/Linux-v4.19/kernel/bpf/
Dsyscall.c1570 static int bpf_prog_attach(const union bpf_attr *attr) in bpf_prog_attach() function
2381 err = bpf_prog_attach(&attr); in SYSCALL_DEFINE3()