Home
last modified time | relevance | path

Searched refs:bpf_prog (Results 1 – 25 of 201) sorted by relevance

123456789

/linux/include/linux/
A Dbpf.h30 struct bpf_prog;
109 struct bpf_prog *new);
542 struct bpf_prog *prog;
706 struct bpf_prog *prog;
771 struct bpf_prog *to);
869 struct bpf_prog *dst_prog;
884 struct bpf_prog **func;
895 struct bpf_prog *prog;
961 struct bpf_prog *prog;
1153 struct bpf_prog *prog;
[all …]
A Dfilter.h562 struct bpf_prog { struct
597 struct bpf_prog *prog; argument
811 void bpf_prog_change_xdp(struct bpf_prog *prev_prog, struct bpf_prog *prog);
908 struct bpf_prog *bpf_prog_select_runtime(struct bpf_prog *fp, int *err);
921 struct bpf_prog *bpf_prog_realloc(struct bpf_prog *fp_old, unsigned int size,
955 struct bpf_prog *bpf_int_jit_compile(struct bpf_prog *prog);
969 struct bpf_prog *bpf_patch_insn_single(struct bpf_prog *prog, u32 off,
1021 struct bpf_prog *prog);
1074 struct bpf_prog *bpf_jit_blind_constants(struct bpf_prog *fp);
1075 void bpf_jit_prog_release_other(struct bpf_prog *fp, struct bpf_prog *fp_other);
[all …]
A Dbpf-netns.h32 struct bpf_prog;
38 struct bpf_prog *prog);
41 struct bpf_prog *prog);
50 struct bpf_prog *prog) in netns_bpf_prog_attach()
62 struct bpf_prog *prog) in netns_bpf_link_create()
A Dtrace_events.h17 struct bpf_prog;
859 void bpf_trace_run1(struct bpf_prog *prog, u64 arg1);
860 void bpf_trace_run2(struct bpf_prog *prog, u64 arg1, u64 arg2);
861 void bpf_trace_run3(struct bpf_prog *prog, u64 arg1, u64 arg2,
863 void bpf_trace_run4(struct bpf_prog *prog, u64 arg1, u64 arg2,
865 void bpf_trace_run5(struct bpf_prog *prog, u64 arg1, u64 arg2,
867 void bpf_trace_run6(struct bpf_prog *prog, u64 arg1, u64 arg2,
869 void bpf_trace_run7(struct bpf_prog *prog, u64 arg1, u64 arg2,
871 void bpf_trace_run8(struct bpf_prog *prog, u64 arg1, u64 arg2,
874 void bpf_trace_run9(struct bpf_prog *prog, u64 arg1, u64 arg2,
[all …]
A Dbpf-cgroup.h18 struct bpf_prog;
125 struct bpf_prog *prog;
209 struct bpf_cgroup_storage *bpf_cgroup_storage_alloc(struct bpf_prog *prog,
446 enum bpf_prog_type ptype, struct bpf_prog *prog);
449 int cgroup_bpf_link_attach(const union bpf_attr *attr, struct bpf_prog *prog);
460 struct bpf_prog *prog) in cgroup_bpf_prog_attach()
472 struct bpf_prog *prog) in cgroup_bpf_link_attach()
486 struct bpf_prog *prog, enum bpf_cgroup_storage_type stype) { return NULL; } in bpf_cgroup_storage_alloc()
A Dskmsg.h58 struct bpf_prog *msg_parser;
59 struct bpf_prog *stream_parser;
60 struct bpf_prog *stream_verdict;
61 struct bpf_prog *skb_verdict;
472 static inline void psock_set_prog(struct bpf_prog **pprog, in psock_set_prog()
473 struct bpf_prog *prog) in psock_set_prog()
480 static inline int psock_replace_prog(struct bpf_prog **pprog, in psock_replace_prog()
481 struct bpf_prog *prog, in psock_replace_prog()
482 struct bpf_prog *old) in psock_replace_prog()
/linux/kernel/bpf/
A Dprog_iter.c16 struct bpf_prog *prog; in bpf_prog_seq_start()
33 bpf_prog_put((struct bpf_prog *)v); in bpf_prog_seq_next()
39 __bpf_md_ptr(struct bpf_prog *, prog);
42 DEFINE_BPF_ITER_FUNC(bpf_prog, struct bpf_iter_meta *meta, struct bpf_prog *prog) in DEFINE_BPF_ITER_FUNC() argument
48 struct bpf_prog *prog; in DEFINE_BPF_ITER_FUNC()
71 bpf_prog_put((struct bpf_prog *)v); in bpf_prog_seq_stop()
82 BTF_ID(struct, bpf_prog)
A Dcore.c85 struct bpf_prog *fp; in bpf_prog_alloc_no_stats()
119 struct bpf_prog *prog; in bpf_prog_alloc()
223 struct bpf_prog *bpf_prog_realloc(struct bpf_prog *fp_old, unsigned int size, in bpf_prog_realloc()
227 struct bpf_prog *fp; in bpf_prog_realloc()
442 struct bpf_prog *bpf_patch_insn_single(struct bpf_prog *prog, u32 off, in bpf_patch_insn_single()
734 struct bpf_prog *prog; in search_bpf_extables()
1099 static struct bpf_prog *bpf_prog_clone_create(struct bpf_prog *fp_other, in bpf_prog_clone_create()
1103 struct bpf_prog *fp; in bpf_prog_clone_create()
1141 struct bpf_prog *bpf_jit_blind_constants(struct bpf_prog *prog) in bpf_jit_blind_constants()
1903 struct bpf_prog *bpf_prog_select_runtime(struct bpf_prog *fp, int *err) in bpf_prog_select_runtime()
[all …]
A Dcgroup.c42 struct bpf_prog *prog, in bpf_cgroup_storages_alloc()
383 struct bpf_prog *prog, in find_attach_entry()
434 struct bpf_prog *prog, struct bpf_prog *replace_prog, in __cgroup_bpf_attach()
439 struct bpf_prog *old_prog = NULL; in __cgroup_bpf_attach()
527 struct bpf_prog *prog, struct bpf_prog *replace_prog, in cgroup_bpf_attach()
596 struct bpf_prog *new_prog) in __cgroup_bpf_replace()
599 struct bpf_prog *old_prog; in __cgroup_bpf_replace()
699 struct bpf_prog *old_prog; in __cgroup_bpf_detach()
767 struct bpf_prog *prog; in __cgroup_bpf_query()
859 struct bpf_prog *prog; in cgroup_bpf_prog_detach()
[all …]
A Ddispatcher.c25 struct bpf_dispatcher *d, struct bpf_prog *prog) in bpf_dispatcher_find_prog()
43 struct bpf_prog *prog) in bpf_dispatcher_add_prog()
68 struct bpf_prog *prog) in bpf_dispatcher_remove_prog()
132 void bpf_dispatcher_change_prog(struct bpf_dispatcher *d, struct bpf_prog *from, in bpf_dispatcher_change_prog()
133 struct bpf_prog *to) in bpf_dispatcher_change_prog()
A Doffload.c80 int bpf_prog_offload_init(struct bpf_prog *prog, union bpf_attr *attr) in bpf_prog_offload_init()
127 int bpf_prog_offload_verifier_prep(struct bpf_prog *prog) in bpf_prog_offload_verifier_prep()
212 static void __bpf_prog_offload_destroy(struct bpf_prog *prog) in __bpf_prog_offload_destroy()
227 void bpf_prog_offload_destroy(struct bpf_prog *prog) in bpf_prog_offload_destroy()
235 static int bpf_prog_offload_translate(struct bpf_prog *prog) in bpf_prog_offload_translate()
256 int bpf_prog_offload_compile(struct bpf_prog *prog) in bpf_prog_offload_compile()
264 struct bpf_prog *prog;
295 struct bpf_prog *prog) in bpf_prog_offload_info_fill()
546 static bool __bpf_offload_dev_match(struct bpf_prog *prog, in __bpf_offload_dev_match()
567 bool bpf_offload_dev_match(struct bpf_prog *prog, struct net_device *netdev) in bpf_offload_dev_match()
[all …]
A Dbpf_iter.c24 struct bpf_prog *prog;
324 struct bpf_prog *prog) in cache_btf_id()
329 bool bpf_iter_prog_supported(struct bpf_prog *prog) in bpf_iter_prog_supported()
364 bpf_iter_get_func_proto(enum bpf_func_id func_id, const struct bpf_prog *prog) in bpf_iter_get_func_proto()
403 struct bpf_prog *new_prog, in bpf_iter_link_replace()
404 struct bpf_prog *old_prog) in bpf_iter_link_replace()
499 struct bpf_prog *prog) in bpf_iter_link_attach()
569 struct bpf_prog *prog) in init_seq_meta()
584 struct bpf_prog *prog; in prepare_seq_file()
660 struct bpf_prog *bpf_iter_get_info(struct bpf_iter_meta *meta, bool in_stop) in bpf_iter_get_info()
[all …]
A Dtrampoline.c180 struct bpf_prog **progs; in bpf_trampoline_get_progs()
392 static enum bpf_tramp_prog_type bpf_attach_type_to_tramp(struct bpf_prog *prog) in bpf_attach_type_to_tramp()
414 int bpf_trampoline_link_prog(struct bpf_prog *prog, struct bpf_trampoline *tr) in bpf_trampoline_link_prog()
463 int bpf_trampoline_unlink_prog(struct bpf_prog *prog, struct bpf_trampoline *tr) in bpf_trampoline_unlink_prog()
542 static void notrace inc_misses_counter(struct bpf_prog *prog) in inc_misses_counter()
565 u64 notrace __bpf_prog_enter(struct bpf_prog *prog) in __bpf_prog_enter()
577 static void notrace update_prog_stats(struct bpf_prog *prog, in update_prog_stats()
599 void notrace __bpf_prog_exit(struct bpf_prog *prog, u64 start) in __bpf_prog_exit()
608 u64 notrace __bpf_prog_enter_sleepable(struct bpf_prog *prog) in __bpf_prog_enter_sleepable()
620 void notrace __bpf_prog_exit_sleepable(struct bpf_prog *prog, u64 start) in __bpf_prog_exit_sleepable()
A Ddevmap.c60 struct bpf_prog *xdp_prog;
68 struct bpf_prog *xdp_prog;
472 struct bpf_prog *xdp_prog) in __xdp_enqueue()
669 struct bpf_prog *xdp_prog) in dev_map_generic_redirect()
692 struct bpf_prog *xdp_prog) in dev_map_redirect_clone()
853 struct bpf_prog *prog = NULL; in __dev_map_alloc_node()
866 if (val->bpf_prog.fd > 0) { in __dev_map_alloc_node()
867 prog = bpf_prog_get_type_dev(val->bpf_prog.fd, in __dev_map_alloc_node()
879 dev->val.bpf_prog.id = prog->aux->id; in __dev_map_alloc_node()
882 dev->val.bpf_prog.id = 0; in __dev_map_alloc_node()
[all …]
/linux/drivers/net/hyperv/
A Dnetvsc_bpf.c29 struct bpf_prog *prog; in netvsc_run_xdp()
35 prog = rcu_dereference(nvchan->bpf_prog); in netvsc_run_xdp()
91 struct bpf_prog *netvsc_xdp_get(struct netvsc_device *nvdev) in netvsc_xdp_get()
93 return rtnl_dereference(nvdev->chan_table[0].bpf_prog); in netvsc_xdp_get()
96 int netvsc_xdp_set(struct net_device *dev, struct bpf_prog *prog, in netvsc_xdp_set()
100 struct bpf_prog *old_prog; in netvsc_xdp_set()
128 rcu_assign_pointer(nvdev->chan_table[i].bpf_prog, prog); in netvsc_xdp_set()
137 int netvsc_vf_setxdp(struct net_device *vf_netdev, struct bpf_prog *prog) in netvsc_vf_setxdp()
/linux/tools/testing/selftests/net/
A Dpsock_lib.h63 struct sock_fprog bpf_prog; in pair_udp_setfilter() local
65 bpf_prog.filter = bpf_filter; in pair_udp_setfilter()
66 bpf_prog.len = sizeof(bpf_filter) / sizeof(struct sock_filter); in pair_udp_setfilter()
68 if (setsockopt(fd, SOL_SOCKET, SO_ATTACH_FILTER, &bpf_prog, in pair_udp_setfilter()
69 sizeof(bpf_prog))) { in pair_udp_setfilter()
/linux/arch/um/drivers/
A Dvector_user.c782 if (bpf_prog) { in uml_vector_default_bpf()
784 bpf_prog->filter = NULL; in uml_vector_default_bpf()
791 bpf_prog->filter = bpf; in uml_vector_default_bpf()
805 kfree(bpf_prog); in uml_vector_default_bpf()
806 bpf_prog = NULL; in uml_vector_default_bpf()
808 return bpf_prog; in uml_vector_default_bpf()
828 if (bpf_prog == NULL) { in uml_vector_user_bpf()
833 bpf_prog->filter = NULL; in uml_vector_user_bpf()
844 bpf_prog->filter = bpf; in uml_vector_user_bpf()
852 return bpf_prog; in uml_vector_user_bpf()
[all …]
/linux/include/uapi/linux/netfilter/
A Dxt_bpf.h12 struct bpf_prog;
19 struct bpf_prog *filter __attribute__((aligned(8)));
39 struct bpf_prog *filter __attribute__((aligned(8)));
/linux/kernel/bpf/preload/iterators/
A Diterators.bpf.c44 struct bpf_prog *dst_prog;
49 struct bpf_prog { struct
55 struct bpf_prog *prog;
98 struct bpf_prog *prog = ctx->prog; in dump_bpf_prog()
/linux/arch/powerpc/net/
A Dbpf_jit_comp.c27 static int bpf_jit_fixup_subprog_calls(struct bpf_prog *fp, u32 *image, in bpf_jit_fixup_subprog_calls()
88 struct bpf_prog *bpf_int_jit_compile(struct bpf_prog *fp) in bpf_int_jit_compile()
100 struct bpf_prog *org_fp = fp; in bpf_int_jit_compile()
101 struct bpf_prog *tmp_fp; in bpf_int_jit_compile()
/linux/net/netfilter/
A Dxt_bpf.c25 struct bpf_prog **ret) in __bpf_mt_check_bytecode()
43 static int __bpf_mt_check_fd(int fd, struct bpf_prog **ret) in __bpf_mt_check_fd()
45 struct bpf_prog *prog; in __bpf_mt_check_fd()
55 static int __bpf_mt_check_path(const char *path, struct bpf_prog **ret) in __bpf_mt_check_path()
/linux/drivers/media/rc/
A Dbpf-lirc.c83 lirc_mode2_func_proto(enum bpf_func_id func_id, const struct bpf_prog *prog) in lirc_mode2_func_proto()
123 const struct bpf_prog *prog, in lirc_mode2_is_valid_access()
137 static int lirc_bpf_attach(struct rc_dev *rcdev, struct bpf_prog *prog) in lirc_bpf_attach()
175 static int lirc_bpf_detach(struct rc_dev *rcdev, struct bpf_prog *prog) in lirc_bpf_detach()
244 int lirc_prog_attach(const union bpf_attr *attr, struct bpf_prog *prog) in lirc_prog_attach()
265 struct bpf_prog *prog; in lirc_prog_detach()
/linux/tools/testing/selftests/bpf/prog_tests/
A Dxdp_cpumap_attach.c39 val.bpf_prog.fd = prog_fd; in serial_test_xdp_cpumap_attach()
45 ASSERT_EQ(info.id, val.bpf_prog.id, "Match program id to cpumap entry prog_id"); in serial_test_xdp_cpumap_attach()
53 val.bpf_prog.fd = bpf_program__fd(skel->progs.xdp_dummy_prog); in serial_test_xdp_cpumap_attach()
A Dxdp_devmap_attach.c41 val.bpf_prog.fd = dm_fd; in test_xdp_with_devmap_helpers()
47 ASSERT_EQ(info.id, val.bpf_prog.id, "Match program id to devmap entry prog_id"); in test_xdp_with_devmap_helpers()
55 val.bpf_prog.fd = bpf_program__fd(skel->progs.xdp_dummy_prog); in test_xdp_with_devmap_helpers()
/linux/samples/bpf/
A Dxdp_sample.bpf.c97 const struct bpf_prog *xdp, const void *tgt, int err, in BPF_PROG()
105 const struct bpf_prog *xdp, const void *tgt, int err, in BPF_PROG()
113 const struct bpf_prog *xdp, const void *tgt, int err, in BPF_PROG()
121 const struct bpf_prog *xdp, const void *tgt, int err, in BPF_PROG()
182 const struct bpf_prog *xdp, u32 act) in BPF_PROG()

Completed in 65 milliseconds

123456789