Lines Matching refs:bpf_prog

38 struct bpf_prog;
133 void (*map_poke_run)(struct bpf_map *map, u32 key, struct bpf_prog *old,
134 struct bpf_prog *new);
893 bool (*allowed)(const struct bpf_prog *prog);
1020 int (*test_run)(struct bpf_prog *prog, const union bpf_attr *kattr,
1029 const struct bpf_prog *prog);
1035 const struct bpf_prog *prog,
1038 const struct bpf_prog *prog);
1039 int (*gen_epilogue)(struct bpf_insn *insn, const struct bpf_prog *prog,
1046 struct bpf_prog *prog, u32 *target_size);
1062 int (*prepare)(struct bpf_prog *prog);
1063 int (*translate)(struct bpf_prog *prog);
1064 void (*destroy)(struct bpf_prog *prog);
1068 struct bpf_prog *prog;
1206 u64 notrace __bpf_prog_enter_sleepable_recur(struct bpf_prog *prog,
1208 void notrace __bpf_prog_exit_sleepable_recur(struct bpf_prog *prog, u64 start,
1212 typedef u64 (*bpf_trampoline_enter_t)(struct bpf_prog *prog,
1214 typedef void (*bpf_trampoline_exit_t)(struct bpf_prog *prog, u64 start,
1216 bpf_trampoline_enter_t bpf_trampoline_enter(const struct bpf_prog *prog);
1217 bpf_trampoline_exit_t bpf_trampoline_exit(const struct bpf_prog *prog);
1267 struct bpf_prog *extension_prog;
1287 struct bpf_prog *prog;
1356 struct bpf_prog *tgt_prog);
1359 struct bpf_prog *tgt_prog);
1428 void bpf_dispatcher_change_prog(struct bpf_dispatcher *d, struct bpf_prog *from,
1429 struct bpf_prog *to);
1438 bool bpf_prog_has_trampoline(const struct bpf_prog *prog);
1442 struct bpf_prog *tgt_prog) in bpf_trampoline_link_prog()
1448 struct bpf_prog *tgt_prog) in bpf_trampoline_unlink_prog()
1463 struct bpf_prog *from, in bpf_dispatcher_change_prog()
1464 struct bpf_prog *to) {} in bpf_dispatcher_change_prog()
1469 static inline bool bpf_prog_has_trampoline(const struct bpf_prog *prog) in bpf_prog_has_trampoline()
1542 struct bpf_prog *dst_prog;
1564 void (*recursion_detected)(struct bpf_prog *prog); /* callback if recursion is detected */
1569 struct bpf_prog **func;
1584 struct bpf_prog *prog;
1631 struct bpf_prog { struct
1679 struct bpf_prog *prog; argument
1708 int (*update_prog)(struct bpf_link *link, struct bpf_prog *new_prog,
1709 struct bpf_prog *old_prog);
1733 struct bpf_prog *tgt_prog;
1830 const struct bpf_prog *prog);
1937 int bpf_struct_ops_test_run(struct bpf_prog *prog, const union bpf_attr *kattr,
1979 int bpf_prog_ctx_arg_info_init(struct bpf_prog *prog,
1983 int bpf_trampoline_link_cgroup_shim(struct bpf_prog *prog,
1985 void bpf_trampoline_unlink_cgroup_shim(struct bpf_prog *prog);
1987 static inline int bpf_trampoline_link_cgroup_shim(struct bpf_prog *prog, in bpf_trampoline_link_cgroup_shim()
1992 static inline void bpf_trampoline_unlink_cgroup_shim(struct bpf_prog *prog) in bpf_trampoline_unlink_cgroup_shim()
2068 bool bpf_prog_map_compatible(struct bpf_map *map, const struct bpf_prog *fp);
2069 int bpf_prog_calc_tag(struct bpf_prog *fp);
2081 struct bpf_prog *prog,
2100 struct bpf_prog *prog;
2114 struct bpf_prog *null_prog;
2135 struct bpf_prog *old_prog);
2138 struct bpf_prog *prog);
2143 struct bpf_prog *exclude_prog,
2144 struct bpf_prog *include_prog,
2191 typedef u32 (*bpf_prog_run_fn)(const struct bpf_prog *prog, const void *ctx);
2198 const struct bpf_prog *prog; in bpf_prog_run_array()
2238 const struct bpf_prog *prog; in bpf_prog_run_array_uprobe()
2313 struct bpf_prog *bpf_prog_get(u32 ufd);
2314 struct bpf_prog *bpf_prog_get_type_dev(u32 ufd, enum bpf_prog_type type,
2316 void bpf_prog_add(struct bpf_prog *prog, int i);
2317 void bpf_prog_sub(struct bpf_prog *prog, int i);
2318 void bpf_prog_inc(struct bpf_prog *prog);
2319 struct bpf_prog * __must_check bpf_prog_inc_not_zero(struct bpf_prog *prog);
2320 void bpf_prog_put(struct bpf_prog *prog);
2322 void bpf_prog_free_id(struct bpf_prog *prog);
2386 struct bpf_prog *bpf_prog_get_curr_or_next(u32 *id);
2467 int bpf_prog_new_fd(struct bpf_prog *prog);
2470 const struct bpf_link_ops *ops, struct bpf_prog *prog);
2472 const struct bpf_link_ops *ops, struct bpf_prog *prog,
2541 typedef int (*bpf_iter_attach_target_t)(struct bpf_prog *prog,
2551 const struct bpf_prog *prog);
2586 int bpf_iter_prog_supported(struct bpf_prog *prog);
2588 bpf_iter_get_func_proto(enum bpf_func_id func_id, const struct bpf_prog *prog);
2589 int bpf_iter_link_attach(const union bpf_attr *attr, bpfptr_t uattr, struct bpf_prog *prog);
2592 struct bpf_prog *bpf_iter_get_info(struct bpf_iter_meta *meta, bool in_stop);
2593 int bpf_iter_run_prog(struct bpf_prog *prog, void *ctx);
2624 int bpf_check(struct bpf_prog **fp, union bpf_attr *attr, bpfptr_t uattr, u32 uattr_size);
2646 const struct bpf_prog *xdp_prog);
2648 const struct bpf_prog *xdp_prog,
2664 struct bpf_prog *bpf_prog_get_type_path(const char *name, enum bpf_prog_type type);
2667 int bpf_prog_test_run_xdp(struct bpf_prog *prog, const union bpf_attr *kattr,
2669 int bpf_prog_test_run_skb(struct bpf_prog *prog, const union bpf_attr *kattr,
2671 int bpf_prog_test_run_tracing(struct bpf_prog *prog,
2674 int bpf_prog_test_run_flow_dissector(struct bpf_prog *prog,
2677 int bpf_prog_test_run_raw_tp(struct bpf_prog *prog,
2680 int bpf_prog_test_run_sk_lookup(struct bpf_prog *prog,
2683 int bpf_prog_test_run_nf(struct bpf_prog *prog,
2687 const struct bpf_prog *prog,
2704 const struct bpf_prog *prog, in bpf_tracing_btf_ctx_access()
2729 int btf_check_type_match(struct bpf_verifier_log *log, const struct bpf_prog *prog,
2736 struct bpf_prog *bpf_prog_by_id(u32 id);
2740 const struct bpf_prog *prog);
2743 bool bpf_prog_has_kfunc_call(const struct bpf_prog *prog);
2745 bpf_jit_find_kfunc_model(const struct bpf_prog *prog,
2747 int bpf_get_kfunc_addr(const struct bpf_prog *prog, u32 func_id,
2781 void notrace bpf_prog_inc_misses_counter(struct bpf_prog *prog);
2789 static inline struct bpf_prog *bpf_prog_get(u32 ufd) in bpf_prog_get()
2794 static inline struct bpf_prog *bpf_prog_get_type_dev(u32 ufd, in bpf_prog_get_type_dev()
2801 static inline void bpf_prog_add(struct bpf_prog *prog, int i) in bpf_prog_add()
2805 static inline void bpf_prog_sub(struct bpf_prog *prog, int i) in bpf_prog_sub()
2809 static inline void bpf_prog_put(struct bpf_prog *prog) in bpf_prog_put()
2813 static inline void bpf_prog_inc(struct bpf_prog *prog) in bpf_prog_inc()
2817 static inline struct bpf_prog *__must_check
2818 bpf_prog_inc_not_zero(struct bpf_prog *prog) in bpf_prog_inc_not_zero()
2825 struct bpf_prog *prog) in bpf_link_init()
2830 const struct bpf_link_ops *ops, struct bpf_prog *prog, in bpf_link_init_sleepable()
2919 const struct bpf_prog *xdp_prog) in dev_map_generic_redirect()
2926 const struct bpf_prog *xdp_prog, in dev_map_redirect_multi()
2949 static inline struct bpf_prog *bpf_prog_get_type_path(const char *name, in bpf_prog_get_type_path()
2955 static inline int bpf_prog_test_run_xdp(struct bpf_prog *prog, in bpf_prog_test_run_xdp()
2962 static inline int bpf_prog_test_run_skb(struct bpf_prog *prog, in bpf_prog_test_run_skb()
2969 static inline int bpf_prog_test_run_tracing(struct bpf_prog *prog, in bpf_prog_test_run_tracing()
2976 static inline int bpf_prog_test_run_flow_dissector(struct bpf_prog *prog, in bpf_prog_test_run_flow_dissector()
2983 static inline int bpf_prog_test_run_sk_lookup(struct bpf_prog *prog, in bpf_prog_test_run_sk_lookup()
2994 static inline struct bpf_prog *bpf_prog_by_id(u32 id) in bpf_prog_by_id()
3009 bpf_base_func_proto(enum bpf_func_id func_id, const struct bpf_prog *prog) in bpf_base_func_proto()
3018 static inline bool bpf_prog_has_kfunc_call(const struct bpf_prog *prog) in bpf_prog_has_kfunc_call()
3024 bpf_jit_find_kfunc_model(const struct bpf_prog *prog, in bpf_jit_find_kfunc_model()
3031 bpf_get_kfunc_addr(const struct bpf_prog *prog, u32 func_id, in bpf_get_kfunc_addr()
3047 static inline void bpf_prog_inc_misses_counter(struct bpf_prog *prog) in bpf_prog_inc_misses_counter()
3083 static inline struct bpf_prog *bpf_prog_get_type(u32 ufd, in bpf_prog_get_type()
3092 bool bpf_prog_get_ok(struct bpf_prog *, enum bpf_prog_type *, bool);
3094 int bpf_prog_offload_compile(struct bpf_prog *prog);
3095 void bpf_prog_dev_bound_destroy(struct bpf_prog *prog);
3097 struct bpf_prog *prog);
3108 bool bpf_offload_prog_map_match(struct bpf_prog *prog, struct bpf_map *map);
3118 bool bpf_offload_dev_match(struct bpf_prog *prog, struct net_device *netdev);
3125 void *bpf_dev_bound_resolve_kfunc(struct bpf_prog *prog, u32 func_id);
3126 int bpf_prog_dev_bound_init(struct bpf_prog *prog, union bpf_attr *attr);
3127 int bpf_prog_dev_bound_inherit(struct bpf_prog *new_prog, struct bpf_prog *old_prog);
3140 bool bpf_prog_dev_bound_match(const struct bpf_prog *lhs, const struct bpf_prog *rhs);
3150 int bpf_prog_test_run_syscall(struct bpf_prog *prog,
3154 int sock_map_get_from_fd(const union bpf_attr *attr, struct bpf_prog *prog);
3159 int sock_map_link_create(const union bpf_attr *attr, struct bpf_prog *prog);
3171 static inline void *bpf_dev_bound_resolve_kfunc(struct bpf_prog *prog, in bpf_dev_bound_resolve_kfunc()
3177 static inline int bpf_prog_dev_bound_init(struct bpf_prog *prog, in bpf_prog_dev_bound_init()
3183 static inline int bpf_prog_dev_bound_inherit(struct bpf_prog *new_prog, in bpf_prog_dev_bound_inherit()
3184 struct bpf_prog *old_prog) in bpf_prog_dev_bound_inherit()
3203 static inline bool bpf_prog_dev_bound_match(const struct bpf_prog *lhs, const struct bpf_prog *rhs) in bpf_prog_dev_bound_match()
3227 static inline int bpf_prog_test_run_syscall(struct bpf_prog *prog, in bpf_prog_test_run_syscall()
3236 struct bpf_prog *prog) in sock_map_get_from_fd()
3259 static inline int sock_map_link_create(const union bpf_attr *attr, struct bpf_prog *prog) in sock_map_link_create()
3270 struct bpf_prog *prog; in bpf_prog_inc_misses_counters()
3397 enum bpf_func_id func_id, const struct bpf_prog *prog);
3413 struct bpf_prog *prog,
3433 struct bpf_prog *prog, in bpf_sock_convert_ctx_access()
3462 struct bpf_prog *prog,
3471 struct bpf_prog *prog,
3484 struct bpf_prog *prog, in bpf_tcp_sock_convert_ctx_access()
3499 struct bpf_prog *prog, in bpf_xdp_sock_convert_ctx_access()
3515 struct bpf_prog *new, struct bpf_prog *old);
3566 static inline bool bpf_is_subprog(const struct bpf_prog *prog) in bpf_is_subprog()