/linux/tools/testing/selftests/bpf/prog_tests/ |
H A D | sockopt.c | 29 enum bpf_attach_type expected_attach_type; member 57 .expected_attach_type = 0, 69 .expected_attach_type = BPF_CGROUP_SETSOCKOPT, 80 .expected_attach_type = BPF_CGROUP_GETSOCKOPT, 101 .expected_attach_type = BPF_CGROUP_GETSOCKOPT, 125 .expected_attach_type = BPF_CGROUP_GETSOCKOPT, 151 .expected_attach_type = BPF_CGROUP_GETSOCKOPT, 167 .expected_attach_type = BPF_CGROUP_GETSOCKOPT, 194 .expected_attach_type = BPF_CGROUP_GETSOCKOPT, 212 .expected_attach_type = BPF_CGROUP_GETSOCKOPT, [all …]
|
H A D | section_names.c | 12 enum bpf_attach_type expected_attach_type; member 210 enum bpf_attach_type expected_attach_type; in test_prog_type_by_name() local 215 &expected_attach_type); in test_prog_type_by_name() 227 CHECK(expected_attach_type != test->expected_load.expected_attach_type, in test_prog_type_by_name() 229 expected_attach_type, test->sec_name); in test_prog_type_by_name()
|
H A D | ctx_rewrite.c | 35 enum bpf_attach_type expected_attach_type; member 167 .expected_attach_type = BPF_CGROUP_GETSOCKOPT, 173 .expected_attach_type = BPF_CGROUP_SETSOCKOPT, 179 .expected_attach_type = BPF_CGROUP_SETSOCKOPT, 185 .expected_attach_type = BPF_CGROUP_SETSOCKOPT, 197 .expected_attach_type = BPF_CGROUP_GETSOCKOPT, 202 .expected_attach_type = BPF_CGROUP_GETSOCKOPT, 207 .expected_attach_type = BPF_CGROUP_GETSOCKOPT, 635 enum bpf_attach_type expected_attach_type; member 664 opts.expected_attach_type = pinfo->expected_attach_type; in match_program() [all …]
|
H A D | fexit_stress.c | 26 .expected_attach_type = BPF_TRACE_FEXIT, in serial_test_fexit_stress() 32 trace_opts.expected_attach_type); in serial_test_fexit_stress()
|
H A D | module_fentry_shadow.c | 71 .expected_attach_type = BPF_TRACE_FENTRY, in test_module_fentry_shadow()
|
/linux/tools/testing/selftests/bpf/ |
H A D | test_sock.c |
|
H A D | test_verifier.c | 159 enum bpf_attach_type expected_attach_type; 1561 opts.expected_attach_type = test->expected_attach_type; in do_test_single() 1577 opts.expected_attach_type); in do_test_single() 163 enum bpf_attach_type expected_attach_type; global() member
|
/linux/tools/testing/selftests/bpf/verifier/ |
H A D | sleepable.c | 8 .expected_attach_type = BPF_TRACE_FENTRY, 21 .expected_attach_type = BPF_TRACE_FENTRY, 34 .expected_attach_type = BPF_MODIFY_RETURN, 47 .expected_attach_type = BPF_TRACE_ITER, 61 .expected_attach_type = BPF_LSM_MAC, 85 .expected_attach_type = BPF_TRACE_RAW_TP,
|
H A D | ctx_sk_lookup.c | 259 .expected_attach_type = BPF_SK_LOOKUP, 274 .expected_attach_type = BPF_SK_LOOKUP, 287 .expected_attach_type = BPF_SK_LOOKUP, 301 .expected_attach_type = BPF_SK_LOOKUP, 314 .expected_attach_type = BPF_SK_LOOKUP, 328 .expected_attach_type = BPF_SK_LOOKUP, 342 .expected_attach_type = BPF_SK_LOOKUP, 355 .expected_attach_type = BPF_SK_LOOKUP, 369 .expected_attach_type = BPF_SK_LOOKUP, 383 .expected_attach_type = BPF_SK_LOOKUP, [all …]
|
H A D | bpf_st_mem.c | 13 .expected_attach_type = BPF_SK_LOOKUP, 35 .expected_attach_type = BPF_SK_LOOKUP, 65 .expected_attach_type = BPF_SK_LOOKUP, 93 .expected_attach_type = BPF_SK_LOOKUP,
|
H A D | wide_access.c | 12 .expected_attach_type = BPF_CGROUP_UDP6_SENDMSG, \ 54 .expected_attach_type = BPF_CGROUP_UDP6_SENDMSG, \
|
H A D | event_output.c | 115 .expected_attach_type = BPF_CGROUP_SETSOCKOPT,
|
H A D | atomic_fetch_add.c | 102 .expected_attach_type = BPF_TRACE_FENTRY,
|
/linux/tools/lib/bpf/ |
H A D | libbpf_probes.c | 118 opts.expected_attach_type = BPF_CGROUP_INET4_CONNECT; in probe_prog_load() 121 opts.expected_attach_type = BPF_CGROUP_GETSOCKOPT; in probe_prog_load() 124 opts.expected_attach_type = BPF_SK_LOOKUP; in probe_prog_load() 130 opts.expected_attach_type = BPF_LIRC_MODE2; in probe_prog_load() 138 opts.expected_attach_type = BPF_TRACE_FENTRY; in probe_prog_load() 140 opts.expected_attach_type = BPF_MODIFY_RETURN; in probe_prog_load() 185 opts.expected_attach_type = BPF_NETFILTER; in probe_prog_load()
|
H A D | bpf.h | 77 enum bpf_attach_type expected_attach_type; member
|
/linux/kernel/bpf/ |
H A D | syscall.c | 2564 if (!attr->expected_attach_type) in bpf_prog_load_fixup_attach_type() 2565 attr->expected_attach_type = in bpf_prog_load_fixup_attach_type() 2569 if (!attr->expected_attach_type) in bpf_prog_load_fixup_attach_type() 2570 attr->expected_attach_type = in bpf_prog_load_fixup_attach_type() 2578 enum bpf_attach_type expected_attach_type, in bpf_prog_load_check_attach() argument 2609 switch (expected_attach_type) { in bpf_prog_load_check_attach() 2619 switch (expected_attach_type) { in bpf_prog_load_check_attach() 2642 switch (expected_attach_type) { in bpf_prog_load_check_attach() 2650 switch (expected_attach_type) { in bpf_prog_load_check_attach() 2658 if (expected_attach_type == BPF_SK_LOOKUP) in bpf_prog_load_check_attach() [all …]
|
H A D | bpf_lsm.c | 227 if (prog->expected_attach_type == BPF_LSM_CGROUP) { in bpf_lsm_func_proto() 258 if (prog->expected_attach_type != BPF_LSM_CGROUP) in bpf_lsm_func_proto() 268 if (prog->expected_attach_type != BPF_LSM_CGROUP) in bpf_lsm_func_proto()
|
H A D | cgroup.c | 312 if (pl->prog->expected_attach_type == BPF_LSM_CGROUP) in cgroup_bpf_release() 317 if (pl->link->link.prog->expected_attach_type == BPF_LSM_CGROUP) in cgroup_bpf_release() 2350 if (prog->expected_attach_type == BPF_CGROUP_SETSOCKOPT) in cg_sockopt_func_proto() 2354 if (prog->expected_attach_type == BPF_CGROUP_SETSOCKOPT) in cg_sockopt_func_proto() 2387 return prog->expected_attach_type == in cg_sockopt_is_valid_access() 2394 return prog->expected_attach_type == in cg_sockopt_is_valid_access() 2422 return prog->expected_attach_type == BPF_CGROUP_GETSOCKOPT; in cg_sockopt_is_valid_access() 2548 switch (prog->expected_attach_type) { in cgroup_common_func_proto() 2566 switch (prog->expected_attach_type) { in cgroup_common_func_proto()
|
H A D | bpf_iter.c | 423 link->prog->expected_attach_type != new_prog->expected_attach_type || in bpf_iter_link_replace()
|
H A D | verifier.c | 7078 prog->expected_attach_type == BPF_LSM_MAC && in get_func_retval_range() 9244 enum bpf_attach_type eatype = env->prog->expected_attach_type; in may_update_sockmap() 10861 env->prog->expected_attach_type == BPF_LSM_CGROUP) { in check_helper_call() 12130 if (env->prog->expected_attach_type == BPF_TRACE_ITER) in check_css_task_iter_allowlist() 16024 if (prog->expected_attach_type == BPF_LSM_CGROUP) in check_return_code() 16072 if (env->prog->expected_attach_type == BPF_CGROUP_UDP4_RECVMSG || in check_return_code() 16073 env->prog->expected_attach_type == BPF_CGROUP_UDP6_RECVMSG || in check_return_code() 16074 env->prog->expected_attach_type == BPF_CGROUP_UNIX_RECVMSG || in check_return_code() 16075 env->prog->expected_attach_type == BPF_CGROUP_INET4_GETPEERNAME || in check_return_code() 16076 env->prog->expected_attach_type == BPF_CGROUP_INET6_GETPEERNAME || in check_return_code() [all …]
|
/linux/kernel/trace/ |
H A D | bpf_trace.c | 956 prog->expected_attach_type == BPF_TRACE_ITER) in BTF_ID() 1575 return prog->expected_attach_type == BPF_TRACE_KPROBE_MULTI || in is_kprobe_multi() 1576 prog->expected_attach_type == BPF_TRACE_KPROBE_SESSION; in is_kprobe_multi() 1581 return prog->expected_attach_type == BPF_TRACE_KPROBE_SESSION; in is_kprobe_session() 1586 return prog->expected_attach_type == BPF_TRACE_UPROBE_MULTI || in is_uprobe_multi() 1587 prog->expected_attach_type == BPF_TRACE_UPROBE_SESSION; in is_uprobe_multi() 1592 return prog->expected_attach_type == BPF_TRACE_UPROBE_SESSION; in is_uprobe_session() 2014 return prog->expected_attach_type == BPF_TRACE_ITER ? in tracing_prog_func_proto() 2018 return prog->expected_attach_type == BPF_TRACE_ITER ? in tracing_prog_func_proto() 2022 return prog->expected_attach_type == BPF_TRACE_ITER ? in tracing_prog_func_proto() [all …]
|
/linux/tools/bpf/bpftool/ |
H A D | prog.c | 1455 enum bpf_attach_type *expected_attach_type) in get_prog_type_by_name() 1460 ret = libbpf_prog_type_by_name(name, prog_type, expected_attach_type); in get_prog_type_by_name() 1466 ret = libbpf_prog_type_by_name(name, prog_type, expected_attach_type); in auto_attach_program() 1526 enum bpf_attach_type expected_attach_type; in load_with_options() 1559 &expected_attach_type); in load_with_options() 1573 &expected_attach_type); in load_with_options() 1710 &expected_attach_type); in load_with_options() 1723 bpf_program__set_expected_attach_type(pos, expected_attach_type); in load_with_options() 1448 get_prog_type_by_name(const char * name,enum bpf_prog_type * prog_type,enum bpf_attach_type * expected_attach_type) get_prog_type_by_name() argument 1519 enum bpf_attach_type expected_attach_type; load_with_options() local
|
/linux/net/core/ |
H A D | sock_reuseport.c | 476 (prog && prog->expected_attach_type == BPF_SK_REUSEPORT_SELECT_OR_MIGRATE)) { in reuseport_stop_listen_sock() 646 if (!prog || prog->expected_attach_type != BPF_SK_REUSEPORT_SELECT_OR_MIGRATE) { in reuseport_migrate_sock()
|
/linux/net/bpf/ |
H A D | bpf_dummy_struct_ops.c | 176 op_idx = prog->expected_attach_type; in bpf_struct_ops_test_run()
|
/linux/net/ipv4/ |
H A D | bpf_tcp_ca.c | 144 midx = prog->expected_attach_type; in prog_ops_moff()
|