Lines Matching defs:env

360 	struct bpf_verifier_env *env = private_data;  in verbose()  local
371 static void verbose_invalid_scalar(struct bpf_verifier_env *env, in verbose_invalid_scalar()
425 static bool subprog_is_global(const struct bpf_verifier_env *env, int subprog) in subprog_is_global()
432 static const char *subprog_name(const struct bpf_verifier_env *env, int subprog) in subprog_name()
443 static void mark_subprog_exc_cb(struct bpf_verifier_env *env, int subprog) in mark_subprog_exc_cb()
452 static bool subprog_is_exc_cb(struct bpf_verifier_env *env, int subprog) in subprog_is_exc_cb()
547 static bool is_may_goto_insn_at(struct bpf_verifier_env *env, int insn_idx) in is_may_goto_insn_at()
587 static struct bpf_func_state *func(struct bpf_verifier_env *env, in func()
609 static int stack_slot_obj_get_spi(struct bpf_verifier_env *env, struct bpf_reg_state *reg, in stack_slot_obj_get_spi()
636 static int dynptr_get_spi(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in dynptr_get_spi()
641 static int iter_get_spi(struct bpf_verifier_env *env, struct bpf_reg_state *reg, int nr_slots) in iter_get_spi()
646 static int irq_flag_get_spi(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in irq_flag_get_spi()
695 static void mark_dynptr_stack_regs(struct bpf_verifier_env *env, in mark_dynptr_stack_regs()
706 static void mark_dynptr_cb_reg(struct bpf_verifier_env *env, in mark_dynptr_cb_reg()
716 static int mark_stack_slots_dynptr(struct bpf_verifier_env *env, struct bpf_reg_state *reg, in mark_stack_slots_dynptr()
777 static void invalidate_dynptr(struct bpf_verifier_env *env, struct bpf_func_state *state, int spi) in invalidate_dynptr()
814 static int unmark_stack_slots_dynptr(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in unmark_stack_slots_dynptr()
863 static void mark_reg_invalid(const struct bpf_verifier_env *env, struct bpf_reg_state *reg) in mark_reg_invalid()
871 static int destroy_if_dynptr_stack_slot(struct bpf_verifier_env *env, in destroy_if_dynptr_stack_slot()
927 static bool is_dynptr_reg_valid_uninit(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in is_dynptr_reg_valid_uninit()
955 static bool is_dynptr_reg_valid_init(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in is_dynptr_reg_valid_init()
984 static bool is_dynptr_type_expected(struct bpf_verifier_env *env, struct bpf_reg_state *reg, in is_dynptr_type_expected()
1012 static int mark_stack_slots_iter(struct bpf_verifier_env *env, in mark_stack_slots_iter()
1056 static int unmark_stack_slots_iter(struct bpf_verifier_env *env, in unmark_stack_slots_iter()
1087 static bool is_iter_reg_valid_uninit(struct bpf_verifier_env *env, in is_iter_reg_valid_uninit()
1114 static int is_iter_reg_valid_init(struct bpf_verifier_env *env, struct bpf_reg_state *reg, in is_iter_reg_valid_init()
1149 static int mark_stack_slot_irq_flag(struct bpf_verifier_env *env, in mark_stack_slot_irq_flag()
1181 static int unmark_stack_slot_irq_flag(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in unmark_stack_slot_irq_flag()
1224 static bool is_irq_flag_reg_valid_uninit(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in is_irq_flag_reg_valid_uninit()
1248 static int is_irq_flag_reg_valid_init(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in is_irq_flag_reg_valid_init()
1326 static void mark_stack_slot_misc(struct bpf_verifier_env *env, u8 *stype) in mark_stack_slot_misc()
1442 static int grow_stack_state(struct bpf_verifier_env *env, struct bpf_func_state *state, int size) in grow_stack_state()
1471 static struct bpf_reference_state *acquire_reference_state(struct bpf_verifier_env *env, int insn_i… in acquire_reference_state()
1485 static int acquire_reference(struct bpf_verifier_env *env, int insn_idx) in acquire_reference()
1497 static int acquire_lock_state(struct bpf_verifier_env *env, int insn_idx, enum ref_state_type type, in acquire_lock_state()
1514 static int acquire_irq_state(struct bpf_verifier_env *env, int insn_idx) in acquire_irq_state()
1679 static u32 state_htab_size(struct bpf_verifier_env *env) in state_htab_size()
1684 static struct bpf_verifier_state_list **explored_state(struct bpf_verifier_env *env, int idx) in explored_state()
1863 static void update_branch_counts(struct bpf_verifier_env *env, struct bpf_verifier_state *st) in update_branch_counts()
1888 static int pop_stack(struct bpf_verifier_env *env, int *prev_insn_idx, in pop_stack()
1917 static struct bpf_verifier_state *push_stack(struct bpf_verifier_env *env, in push_stack()
2015 static void __mark_reg_const_zero(const struct bpf_verifier_env *env, struct bpf_reg_state *reg) in __mark_reg_const_zero()
2025 static void mark_reg_known_zero(struct bpf_verifier_env *env, in mark_reg_known_zero()
2475 static int reg_bounds_sanity_check(struct bpf_verifier_env *env, in reg_bounds_sanity_check()
2569 static void __mark_reg_unknown(const struct bpf_verifier_env *env, in __mark_reg_unknown()
2576 static void mark_reg_unknown(struct bpf_verifier_env *env, in mark_reg_unknown()
2589 static int __mark_reg_s32_range(struct bpf_verifier_env *env, in __mark_reg_s32_range()
2608 static void __mark_reg_not_init(const struct bpf_verifier_env *env, in __mark_reg_not_init()
2615 static void mark_reg_not_init(struct bpf_verifier_env *env, in mark_reg_not_init()
2628 static void mark_btf_ld_reg(struct bpf_verifier_env *env, in mark_btf_ld_reg()
2647 static void init_reg_state(struct bpf_verifier_env *env, in init_reg_state()
2672 static void init_func_state(struct bpf_verifier_env *env, in init_func_state()
2685 static struct bpf_verifier_state *push_async_cb(struct bpf_verifier_env *env, in push_async_cb()
2751 static struct bpf_subprog_info *find_containing_subprog(struct bpf_verifier_env *env, int off) in find_containing_subprog()
2772 static int find_subprog(struct bpf_verifier_env *env, int off) in find_subprog()
2782 static int add_subprog(struct bpf_verifier_env *env, int off) in add_subprog()
2805 static int bpf_find_exception_callback_insn_off(struct bpf_verifier_env *env) in bpf_find_exception_callback_insn_off()
2943 static struct btf *__find_kfunc_desc_btf(struct bpf_verifier_env *env, in __find_kfunc_desc_btf()
3019 static struct btf *find_kfunc_desc_btf(struct bpf_verifier_env *env, s16 offset) in find_kfunc_desc_btf()
3035 static int add_kfunc_call(struct bpf_verifier_env *env, u32 func_id, s16 offset) in add_kfunc_call()
3209 static int add_subprog_and_kfunc(struct bpf_verifier_env *env) in add_subprog_and_kfunc()
3272 static int check_subprogs(struct bpf_verifier_env *env) in check_subprogs()
3330 static int mark_reg_read(struct bpf_verifier_env *env, in mark_reg_read()
3378 static int mark_stack_slot_obj_read(struct bpf_verifier_env *env, struct bpf_reg_state *reg, in mark_stack_slot_obj_read()
3396 static int mark_dynptr_read(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in mark_dynptr_read()
3416 static int mark_iter_read(struct bpf_verifier_env *env, struct bpf_reg_state *reg, in mark_iter_read()
3422 static int mark_irq_flag_read(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in mark_irq_flag_read()
3436 static bool is_reg64(struct bpf_verifier_env *env, struct bpf_insn *insn, in is_reg64()
3547 static bool insn_has_def32(struct bpf_verifier_env *env, struct bpf_insn *insn) in insn_has_def32()
3557 static void mark_insn_zext(struct bpf_verifier_env *env, in mark_insn_zext()
3570 static int __check_reg_arg(struct bpf_verifier_env *env, struct bpf_reg_state *regs, u32 regno, in __check_reg_arg()
3615 static int check_reg_arg(struct bpf_verifier_env *env, u32 regno, in check_reg_arg()
3639 static void mark_jmp_point(struct bpf_verifier_env *env, int idx) in mark_jmp_point()
3644 static bool is_jmp_point(struct bpf_verifier_env *env, int insn_idx) in is_jmp_point()
3728 static int push_insn_history(struct bpf_verifier_env *env, struct bpf_verifier_state *cur, in push_insn_history()
3772 static struct bpf_insn_hist_entry *get_insn_hist_entry(struct bpf_verifier_env *env, in get_insn_hist_entry()
3793 static int get_prev_insn_idx(const struct bpf_verifier_env *env, in get_prev_insn_idx()
3838 struct bpf_verifier_env *env = bt->env; in bt_reset() local
4028 static int backtrack_insn(struct bpf_verifier_env *env, int idx, int subseq_idx, in backtrack_insn()
4369 static void mark_all_scalars_precise(struct bpf_verifier_env *env, in mark_all_scalars_precise()
4416 static void mark_all_scalars_imprecise(struct bpf_verifier_env *env, struct bpf_verifier_state *st) in mark_all_scalars_imprecise()
4528 static int __mark_chain_precision(struct bpf_verifier_env *env, int regno) in __mark_chain_precision()
4708 int mark_chain_precision(struct bpf_verifier_env *env, int regno) in mark_chain_precision()
4716 static int mark_chain_precision_batch(struct bpf_verifier_env *env) in mark_chain_precision_batch()
4776 static void assign_scalar_id_before_mov(struct bpf_verifier_env *env, in assign_scalar_id_before_mov()
4811 static void save_register_state(struct bpf_verifier_env *env, in save_register_state()
4841 static void check_fastcall_stack_contract(struct bpf_verifier_env *env, in check_fastcall_stack_contract()
4868 static int check_stack_write_fixed_off(struct bpf_verifier_env *env, in check_stack_write_fixed_off()
5013 static int check_stack_write_var_off(struct bpf_verifier_env *env, in check_stack_write_var_off()
5131 static void mark_reg_stack_read(struct bpf_verifier_env *env, in mark_reg_stack_read()
5172 static int check_stack_read_fixed_off(struct bpf_verifier_env *env, in check_stack_read_fixed_off()
5312 static struct bpf_reg_state *reg_state(struct bpf_verifier_env *env, int regno) in reg_state()
5330 static int check_stack_read_var_off(struct bpf_verifier_env *env, in check_stack_read_var_off()
5362 static int check_stack_read(struct bpf_verifier_env *env, in check_stack_read()
5419 static int check_stack_write(struct bpf_verifier_env *env, in check_stack_write()
5442 static int check_map_access_type(struct bpf_verifier_env *env, u32 regno, in check_map_access_type()
5465 static int __check_mem_access(struct bpf_verifier_env *env, int regno, in __check_mem_access()
5501 static int check_mem_region_access(struct bpf_verifier_env *env, u32 regno, in check_mem_region_access()
5556 static int __check_ptr_off_reg(struct bpf_verifier_env *env, in __check_ptr_off_reg()
5588 static int check_ptr_off_reg(struct bpf_verifier_env *env, in check_ptr_off_reg()
5594 static int map_kptr_match_type(struct bpf_verifier_env *env, in map_kptr_match_type()
5670 static bool in_sleepable(struct bpf_verifier_env *env) in in_sleepable()
5679 static bool in_rcu_cs(struct bpf_verifier_env *env) in in_rcu_cs()
5731 static u32 btf_ld_kptr_type(struct bpf_verifier_env *env, struct btf_field *kptr_field) in btf_ld_kptr_type()
5754 static int mark_uptr_ld_reg(struct bpf_verifier_env *env, u32 regno, in mark_uptr_ld_reg()
5770 static int check_map_kptr_access(struct bpf_verifier_env *env, u32 regno, in check_map_kptr_access()
5831 static int check_map_access(struct bpf_verifier_env *env, u32 regno, in check_map_access()
5899 static bool may_access_direct_pkt_data(struct bpf_verifier_env *env, in may_access_direct_pkt_data()
5941 static int check_packet_access(struct bpf_verifier_env *env, u32 regno, int off, in check_packet_access()
5984 static int check_ctx_access(struct bpf_verifier_env *env, int insn_idx, int off, int size, in check_ctx_access()
6023 static int check_flow_keys_access(struct bpf_verifier_env *env, int off, in check_flow_keys_access()
6035 static int check_sock_access(struct bpf_verifier_env *env, int insn_idx, in check_sock_access()
6080 static bool is_pointer_value(struct bpf_verifier_env *env, int regno) in is_pointer_value()
6085 static bool is_ctx_reg(struct bpf_verifier_env *env, int regno) in is_ctx_reg()
6092 static bool is_sk_reg(struct bpf_verifier_env *env, int regno) in is_sk_reg()
6099 static bool is_pkt_reg(struct bpf_verifier_env *env, int regno) in is_pkt_reg()
6106 static bool is_flow_key_reg(struct bpf_verifier_env *env, int regno) in is_flow_key_reg()
6114 static bool is_arena_reg(struct bpf_verifier_env *env, int regno) in is_arena_reg()
6164 static int check_pkt_ptr_alignment(struct bpf_verifier_env *env, in check_pkt_ptr_alignment()
6199 static int check_generic_ptr_alignment(struct bpf_verifier_env *env, in check_generic_ptr_alignment()
6223 static int check_ptr_alignment(struct bpf_verifier_env *env, in check_ptr_alignment()
6306 static int round_up_stack_depth(struct bpf_verifier_env *env, int stack_depth) in round_up_stack_depth()
6323 static int check_max_stack_depth_subprog(struct bpf_verifier_env *env, int idx, in check_max_stack_depth_subprog()
6487 static int check_max_stack_depth(struct bpf_verifier_env *env) in check_max_stack_depth()
6532 static int get_callee_stack_depth(struct bpf_verifier_env *env, in get_callee_stack_depth()
6547 static int __check_buffer_access(struct bpf_verifier_env *env, in __check_buffer_access()
6571 static int check_tp_buffer_access(struct bpf_verifier_env *env, in check_tp_buffer_access()
6587 static int check_buffer_access(struct bpf_verifier_env *env, in check_buffer_access()
6910 static bool type_is_rcu(struct bpf_verifier_env *env, in type_is_rcu()
6921 static bool type_is_rcu_or_null(struct bpf_verifier_env *env, in type_is_rcu_or_null()
6932 static bool type_is_trusted(struct bpf_verifier_env *env, in type_is_trusted()
6945 static bool type_is_trusted_or_null(struct bpf_verifier_env *env, in type_is_trusted_or_null()
6955 static int check_ptr_to_btf_access(struct bpf_verifier_env *env, in check_ptr_to_btf_access()
7105 static int check_ptr_to_map_access(struct bpf_verifier_env *env, in check_ptr_to_map_access()
7171 static int check_stack_slot_within_bounds(struct bpf_verifier_env *env, in check_stack_slot_within_bounds()
7194 struct bpf_verifier_env *env, in check_stack_access_within_bounds()
7270 static int check_mem_access(struct bpf_verifier_env *env, int insn_idx, u32 regno, in check_mem_access()
7521 static int check_atomic(struct bpf_verifier_env *env, int insn_idx, struct bpf_insn *insn) in check_atomic()
7641 struct bpf_verifier_env *env, int regno, int off, in check_stack_range_initialized()
7786 static int check_helper_mem_access(struct bpf_verifier_env *env, int regno, in check_helper_mem_access()
7883 static int check_mem_size_reg(struct bpf_verifier_env *env, in check_mem_size_reg()
7933 static int check_mem_reg(struct bpf_verifier_env *env, struct bpf_reg_state *reg, in check_mem_reg()
7961 static int check_kfunc_mem_size_reg(struct bpf_verifier_env *env, struct bpf_reg_state *reg, in check_kfunc_mem_size_reg()
8010 static int process_spin_lock(struct bpf_verifier_env *env, int regno, in process_spin_lock()
8092 static int process_timer_func(struct bpf_verifier_env *env, int regno, in process_timer_func()
8129 static int process_wq_func(struct bpf_verifier_env *env, int regno, in process_wq_func()
8146 static int process_kptr_func(struct bpf_verifier_env *env, int regno, in process_kptr_func()
8219 static int process_dynptr_func(struct bpf_verifier_env *env, int regno, int insn_idx, in process_dynptr_func()
8299 static u32 iter_ref_obj_id(struct bpf_verifier_env *env, struct bpf_reg_state *reg, int spi) in iter_ref_obj_id()
8339 static int process_iter_arg(struct bpf_verifier_env *env, int regno, int insn_idx, in process_iter_arg()
8428 static struct bpf_verifier_state *find_prev_entry(struct bpf_verifier_env *env, in find_prev_entry()
8455 static void maybe_widen_reg(struct bpf_verifier_env *env, in maybe_widen_reg()
8468 static int widen_imprecise_scalars(struct bpf_verifier_env *env, in widen_imprecise_scalars()
8587 static int process_iter_next_call(struct bpf_verifier_env *env, int insn_idx, in process_iter_next_call()
8664 static int resolve_map_arg_type(struct bpf_verifier_env *env, in resolve_map_arg_type()
8805 static int check_reg_type(struct bpf_verifier_env *env, u32 regno, in check_reg_type()
8969 static int check_func_arg_reg_off(struct bpf_verifier_env *env, in check_func_arg_reg_off()
9040 static struct bpf_reg_state *get_dynptr_arg_reg(struct bpf_verifier_env *env, in get_dynptr_arg_reg()
9062 static int dynptr_id(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in dynptr_id()
9075 static int dynptr_ref_obj_id(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in dynptr_ref_obj_id()
9088 static enum bpf_dynptr_type dynptr_get_type(struct bpf_verifier_env *env, in dynptr_get_type()
9106 static int check_reg_const_str(struct bpf_verifier_env *env, in check_reg_const_str()
9155 static int get_constant_map_key(struct bpf_verifier_env *env, in get_constant_map_key()
9217 static int check_func_arg(struct bpf_verifier_env *env, u32 arg, in check_func_arg()
9487 static bool may_update_sockmap(struct bpf_verifier_env *env, int func_id) in may_update_sockmap()
9525 static bool allow_tail_call_in_subprogs(struct bpf_verifier_env *env) in allow_tail_call_in_subprogs()
9531 static int check_map_func_compatibility(struct bpf_verifier_env *env, in check_map_func_compatibility()
9869 static void clear_all_pkt_pointers(struct bpf_verifier_env *env) in clear_all_pkt_pointers()
9926 static int release_reference(struct bpf_verifier_env *env, int ref_obj_id) in release_reference()
9945 static void invalidate_non_owning_refs(struct bpf_verifier_env *env) in invalidate_non_owning_refs()
9956 static void clear_caller_saved_regs(struct bpf_verifier_env *env, in clear_caller_saved_regs()
9977 static int setup_func_entry(struct bpf_verifier_env *env, int subprog, int callsite, in setup_func_entry()
10026 static int btf_check_func_arg_match(struct bpf_verifier_env *env, int subprog, in btf_check_func_arg_match()
10122 static int btf_check_subprog_call(struct bpf_verifier_env *env, int subprog, in btf_check_subprog_call()
10150 static int push_callback_call(struct bpf_verifier_env *env, struct bpf_insn *insn, in push_callback_call()
10219 static int check_func_call(struct bpf_verifier_env *env, struct bpf_insn *insn, in check_func_call()
10304 int map_set_for_each_callback_args(struct bpf_verifier_env *env, in map_set_for_each_callback_args()
10331 static int set_callee_state(struct bpf_verifier_env *env, in set_callee_state()
10345 static int set_map_elem_callback_state(struct bpf_verifier_env *env, in set_map_elem_callback_state()
10371 static int set_loop_callback_state(struct bpf_verifier_env *env, in set_loop_callback_state()
10393 static int set_timer_callback_state(struct bpf_verifier_env *env, in set_timer_callback_state()
10423 static int set_find_vma_callback_state(struct bpf_verifier_env *env, in set_find_vma_callback_state()
10451 static int set_user_ringbuf_callback_state(struct bpf_verifier_env *env, in set_user_ringbuf_callback_state()
10474 static int set_rbtree_add_callback_state(struct bpf_verifier_env *env, in set_rbtree_add_callback_state()
10512 static bool in_rbtree_lock_required_cb(struct bpf_verifier_env *env) in in_rbtree_lock_required_cb()
10540 static int prepare_func_exit(struct bpf_verifier_env *env, int *insn_idx) in prepare_func_exit()
10631 static int do_refine_retval_range(struct bpf_verifier_env *env, in do_refine_retval_range()
10670 record_func_map(struct bpf_verifier_env *env, struct bpf_call_arg_meta *meta, in record_func_map()
10716 record_func_key(struct bpf_verifier_env *env, struct bpf_call_arg_meta *meta, in record_func_key()
10752 static int check_reference_leak(struct bpf_verifier_env *env, bool exception_exit) in check_reference_leak()
10771 static int check_resource_leak(struct bpf_verifier_env *env, bool exception_exit, bool check_lock, … in check_resource_leak()
10804 static int check_bpf_snprintf_call(struct bpf_verifier_env *env, in check_bpf_snprintf_call()
10842 static int check_get_func_ip(struct bpf_verifier_env *env) in check_get_func_ip()
10863 static struct bpf_insn_aux_data *cur_aux(struct bpf_verifier_env *env) in cur_aux()
10868 static bool loop_flag_is_zero(struct bpf_verifier_env *env) in loop_flag_is_zero()
10880 static void update_loop_inline_state(struct bpf_verifier_env *env, u32 subprogno) in update_loop_inline_state()
10913 static int get_helper_proto(struct bpf_verifier_env *env, int func_id, in get_helper_proto()
10926 static int check_helper_call(struct bpf_verifier_env *env, struct bpf_insn *insn, in check_helper_call()
11462 static void mark_btf_func_reg_size(struct bpf_verifier_env *env, u32 regno, in mark_btf_func_reg_size()
11677 static bool is_kfunc_arg_callback(struct bpf_verifier_env *env, const struct btf *btf, in is_kfunc_arg_callback()
11690 static bool __btf_type_is_scalar_struct(struct bpf_verifier_env *env, in __btf_type_is_scalar_struct()
11894 get_kfunc_ptr_arg_type(struct bpf_verifier_env *env, in get_kfunc_ptr_arg_type()
11986 static int process_kf_arg_ptr_to_btf_id(struct bpf_verifier_env *env, in process_kf_arg_ptr_to_btf_id()
12058 static int process_irq_flag(struct bpf_verifier_env *env, int regno, in process_irq_flag()
12106 static int ref_set_non_owning(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in ref_set_non_owning()
12127 static int ref_convert_owning_non_owning(struct bpf_verifier_env *env, u32 ref_obj_id) in ref_convert_owning_non_owning()
12204 static int check_reg_allocation_locked(struct bpf_verifier_env *env, struct bpf_reg_state *reg) in check_reg_allocation_locked()
12298 static bool check_kfunc_is_graph_root_api(struct bpf_verifier_env *env, in check_kfunc_is_graph_root_api()
12323 static bool check_kfunc_is_graph_node_api(struct bpf_verifier_env *env, in check_kfunc_is_graph_node_api()
12351 __process_kf_arg_ptr_to_graph_root(struct bpf_verifier_env *env, in __process_kf_arg_ptr_to_graph_root()
12401 static int process_kf_arg_ptr_to_list_head(struct bpf_verifier_env *env, in process_kf_arg_ptr_to_list_head()
12409 static int process_kf_arg_ptr_to_rbtree_root(struct bpf_verifier_env *env, in process_kf_arg_ptr_to_rbtree_root()
12418 __process_kf_arg_ptr_to_graph_node(struct bpf_verifier_env *env, in __process_kf_arg_ptr_to_graph_node()
12482 static int process_kf_arg_ptr_to_list_node(struct bpf_verifier_env *env, in process_kf_arg_ptr_to_list_node()
12491 static int process_kf_arg_ptr_to_rbtree_node(struct bpf_verifier_env *env, in process_kf_arg_ptr_to_rbtree_node()
12506 static bool check_css_task_iter_allowlist(struct bpf_verifier_env *env) in check_css_task_iter_allowlist()
12522 static int check_kfunc_args(struct bpf_verifier_env *env, struct bpf_kfunc_call_arg_meta *meta, in check_kfunc_args()
13005 static int fetch_kfunc_meta(struct bpf_verifier_env *env, in fetch_kfunc_meta()
13049 static int check_kfunc_call(struct bpf_verifier_env *env, struct bpf_insn *insn, in check_kfunc_call()
13517 static bool check_reg_sane_offset(struct bpf_verifier_env *env, in check_reg_sane_offset()
13591 static bool can_skip_alu_sanitation(const struct bpf_verifier_env *env, in can_skip_alu_sanitation()
13614 static int sanitize_val_alu(struct bpf_verifier_env *env, in sanitize_val_alu()
13636 sanitize_speculative_path(struct bpf_verifier_env *env, in sanitize_speculative_path()
13656 static int sanitize_ptr_alu(struct bpf_verifier_env *env, in sanitize_ptr_alu()
13752 static void sanitize_mark_insn_seen(struct bpf_verifier_env *env) in sanitize_mark_insn_seen()
13765 static int sanitize_err(struct bpf_verifier_env *env, in sanitize_err()
13815 struct bpf_verifier_env *env, in check_stack_access_for_ptr_arithmetic()
13838 static int sanitize_check_bounds(struct bpf_verifier_env *env, in sanitize_check_bounds()
13875 static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env, in adjust_ptr_min_max_vals()
14674 static int adjust_scalar_min_max_vals(struct bpf_verifier_env *env, in adjust_scalar_min_max_vals()
14771 static int adjust_reg_min_max_vals(struct bpf_verifier_env *env, in adjust_reg_min_max_vals()
14906 static int check_alu_op(struct bpf_verifier_env *env, struct bpf_insn *insn) in check_alu_op()
15663 static int reg_set_min_max(struct bpf_verifier_env *env, in reg_set_min_max()
15964 static int check_cond_jmp_op(struct bpf_verifier_env *env, in check_cond_jmp_op()
16204 static int check_ld_imm(struct bpf_verifier_env *env, struct bpf_insn *insn) in check_ld_imm()
16327 static int check_ld_abs(struct bpf_verifier_env *env, struct bpf_insn *insn) in check_ld_abs()
16397 static int check_return_code(struct bpf_verifier_env *env, int regno, const char *reg_name) in check_return_code()
16577 static void mark_subprog_changes_pkt_data(struct bpf_verifier_env *env, int off) in mark_subprog_changes_pkt_data()
16591 static void merge_callee_effects(struct bpf_verifier_env *env, int t, int w) in merge_callee_effects()
16640 static void mark_prune_point(struct bpf_verifier_env *env, int idx) in mark_prune_point()
16645 static bool is_prune_point(struct bpf_verifier_env *env, int insn_idx) in is_prune_point()
16650 static void mark_force_checkpoint(struct bpf_verifier_env *env, int idx) in mark_force_checkpoint()
16655 static bool is_force_checkpoint(struct bpf_verifier_env *env, int insn_idx) in is_force_checkpoint()
16660 static void mark_calls_callback(struct bpf_verifier_env *env, int idx) in mark_calls_callback()
16665 static bool calls_callback(struct bpf_verifier_env *env, int insn_idx) in calls_callback()
16680 static int push_insn(int t, int w, int e, struct bpf_verifier_env *env) in push_insn()
16729 struct bpf_verifier_env *env, in visit_func_call_insn()
16781 static bool verifier_inlines_helper_call(struct bpf_verifier_env *env, s32 imm) in verifier_inlines_helper_call()
16887 static void mark_fastcall_pattern_for_call(struct bpf_verifier_env *env, in mark_fastcall_pattern_for_call()
16990 static int mark_fastcall_patterns(struct bpf_verifier_env *env) in mark_fastcall_patterns()
17023 static int visit_insn(int t, struct bpf_verifier_env *env) in visit_insn()
17125 static int check_cfg(struct bpf_verifier_env *env) in check_cfg()
17210 static int check_abnormal_return(struct bpf_verifier_env *env) in check_abnormal_return()
17231 static int check_btf_func_early(struct bpf_verifier_env *env, in check_btf_func_early()
17333 static int check_btf_func(struct bpf_verifier_env *env, in check_btf_func()
17408 static void adjust_btf_func(struct bpf_verifier_env *env) in adjust_btf_func()
17424 static int check_btf_line(struct bpf_verifier_env *env, in check_btf_line()
17552 static int check_core_relo(struct bpf_verifier_env *env, in check_core_relo()
17621 static int check_btf_info_early(struct bpf_verifier_env *env, in check_btf_info_early()
17649 static int check_btf_info(struct bpf_verifier_env *env, in check_btf_info()
17741 static void clean_func_state(struct bpf_verifier_env *env, in clean_func_state()
17770 static void clean_verifier_state(struct bpf_verifier_env *env, in clean_verifier_state()
17815 static void clean_live_states(struct bpf_verifier_env *env, int insn, in clean_live_states()
17849 static bool regsafe(struct bpf_verifier_env *env, struct bpf_reg_state *rold, in regsafe()
17987 static bool is_stack_all_misc(struct bpf_verifier_env *env, in is_stack_all_misc()
18002 static struct bpf_reg_state *scalar_reg_for_stack(struct bpf_verifier_env *env, in scalar_reg_for_stack()
18014 static bool stacksafe(struct bpf_verifier_env *env, struct bpf_func_state *old, in stacksafe()
18212 static bool func_states_equal(struct bpf_verifier_env *env, struct bpf_func_state *old, in func_states_equal()
18231 static void reset_idmap_scratch(struct bpf_verifier_env *env) in reset_idmap_scratch()
18237 static bool states_equal(struct bpf_verifier_env *env, in states_equal()
18276 static int propagate_liveness_reg(struct bpf_verifier_env *env, in propagate_liveness_reg()
18309 static int propagate_liveness(struct bpf_verifier_env *env, in propagate_liveness()
18356 static int propagate_precision(struct bpf_verifier_env *env, in propagate_precision()
18430 static bool is_iter_next_insn(struct bpf_verifier_env *env, int insn_idx) in is_iter_next_insn()
18517 static int is_state_visited(struct bpf_verifier_env *env, int insn_idx) in is_state_visited()
18897 static int save_aux_ptr_type(struct bpf_verifier_env *env, enum bpf_reg_type type, in save_aux_ptr_type()
18935 static int do_check(struct bpf_verifier_env *env) in do_check()
19322 static int __add_used_btf(struct bpf_verifier_env *env, struct btf *btf) in __add_used_btf()
19354 static int __check_pseudo_btf_id(struct bpf_verifier_env *env, in __check_pseudo_btf_id()
19437 static int check_pseudo_btf_id(struct bpf_verifier_env *env, in check_pseudo_btf_id()
19492 static int check_map_prog_compatibility(struct bpf_verifier_env *env, in check_map_prog_compatibility()
19603 static int __add_used_map(struct bpf_verifier_env *env, struct bpf_map *map) in __add_used_map()
19641 static int add_used_map(struct bpf_verifier_env *env, int fd) in add_used_map()
19662 static int resolve_pseudo_ldimm64(struct bpf_verifier_env *env) in resolve_pseudo_ldimm64()
19805 static void release_maps(struct bpf_verifier_env *env) in release_maps()
19812 static void release_btfs(struct bpf_verifier_env *env) in release_btfs()
19818 static void convert_pseudo_ld_imm64(struct bpf_verifier_env *env) in convert_pseudo_ld_imm64()
19837 static void adjust_insn_aux_data(struct bpf_verifier_env *env, in adjust_insn_aux_data()
19869 static void adjust_subprog_starts(struct bpf_verifier_env *env, u32 off, u32 len) in adjust_subprog_starts()
19897 static struct bpf_prog *bpf_patch_insn_data(struct bpf_verifier_env *env, u32 off, in bpf_patch_insn_data()
19963 static int adjust_subprog_starts_after_remove(struct bpf_verifier_env *env, in adjust_subprog_starts_after_remove()
20019 static int bpf_adj_linfo_after_remove(struct bpf_verifier_env *env, u32 off, in bpf_adj_linfo_after_remove()
20083 static int verifier_remove_insns(struct bpf_verifier_env *env, u32 off, u32 cnt) in verifier_remove_insns()
20121 static void sanitize_dead_code(struct bpf_verifier_env *env) in sanitize_dead_code()
20151 static void opt_hard_wire_dead_code_branches(struct bpf_verifier_env *env) in opt_hard_wire_dead_code_branches()
20177 static int opt_remove_dead_code(struct bpf_verifier_env *env) in opt_remove_dead_code()
20204 static int opt_remove_nops(struct bpf_verifier_env *env) in opt_remove_nops()
20229 static int opt_subreg_zext_lo32_rnd_hi32(struct bpf_verifier_env *env, in opt_subreg_zext_lo32_rnd_hi32()
20333 static int convert_ctx_accesses(struct bpf_verifier_env *env) in convert_ctx_accesses()
20594 static int jit_subprogs(struct bpf_verifier_env *env) in jit_subprogs()
20858 static int fixup_call_args(struct bpf_verifier_env *env) in fixup_call_args()
20910 static void specialize_kfunc(struct bpf_verifier_env *env, in specialize_kfunc()
20961 static int fixup_kfunc_call(struct bpf_verifier_env *env, struct bpf_insn *insn, in fixup_kfunc_call()
21065 static int add_hidden_subprog(struct bpf_verifier_env *env, struct bpf_insn *patch, int len) in add_hidden_subprog()
21094 static int do_misc_fixups(struct bpf_verifier_env *env) in do_misc_fixups()
21968 static struct bpf_prog *inline_bpf_loop(struct bpf_verifier_env *env, in inline_bpf_loop()
22060 static int optimize_bpf_loop(struct bpf_verifier_env *env) in optimize_bpf_loop()
22108 static int remove_fastcall_spills_fills(struct bpf_verifier_env *env) in remove_fastcall_spills_fills()
22139 static void free_states(struct bpf_verifier_env *env) in free_states()
22169 static int do_check_common(struct bpf_verifier_env *env, int subprog) in do_check_common()
22316 static int do_check_subprogs(struct bpf_verifier_env *env) in do_check_subprogs()
22366 static int do_check_main(struct bpf_verifier_env *env) in do_check_main()
22378 static void print_verification_stats(struct bpf_verifier_env *env) in print_verification_stats()
22402 static int check_struct_ops_btf_id(struct bpf_verifier_env *env) in check_struct_ops_btf_id()
22884 static int check_attach_btf_id(struct bpf_verifier_env *env) in check_attach_btf_id()
22984 static int add_fd_from_fd_array(struct bpf_verifier_env *env, int fd) in add_fd_from_fd_array()
23011 static int process_fd_array(struct bpf_verifier_env *env, union bpf_attr *attr, bpfptr_t uattr) in process_fd_array()
23049 struct bpf_verifier_env *env; in bpf_check() local