Lines Matching refs:PTR_TO_BTF_ID
406 (type == PTR_TO_BTF_ID && is_trusted_reg(reg)) || in reg_not_null()
2186 regs[regno].type = PTR_TO_BTF_ID | MEM_ALLOC; in mark_reg_graph_node()
2739 regs[regno].type = PTR_TO_BTF_ID | flag; in mark_btf_ld_reg()
4863 case PTR_TO_BTF_ID: in is_spillable_regtype()
5741 if (base_type(reg->type) != PTR_TO_BTF_ID || (type_flag(reg->type) & ~perm_flags)) in map_kptr_match_type()
5788 verbose(env, "expected=%s%s", reg_type_str(env, PTR_TO_BTF_ID), targ_name); in map_kptr_match_type()
5790 verbose(env, " or %s%s\n", reg_type_str(env, PTR_TO_BTF_ID | PTR_UNTRUSTED), in map_kptr_match_type()
5937 mark_btf_ld_reg(env, cur_regs(env), value_regno, PTR_TO_BTF_ID, kptr_field->kptr.btf, in check_map_kptr_access()
6123 if (base_type(info->reg_type) == PTR_TO_BTF_ID) { in check_ctx_access()
7179 if (ret != PTR_TO_BTF_ID) { in check_ptr_to_btf_access()
7294 mark_btf_ld_reg(env, &map_reg, 0, PTR_TO_BTF_ID, btf_vmlinux, *map->ops->map_btf_id, 0); in check_ptr_to_map_access()
7553 if (base_type(info.reg_type) == PTR_TO_BTF_ID) { in check_mem_access()
7612 } else if (base_type(reg->type) == PTR_TO_BTF_ID && in check_mem_access()
8098 case PTR_TO_BTF_ID: in check_helper_mem_access()
9012 PTR_TO_BTF_ID,
9013 PTR_TO_BTF_ID | PTR_TRUSTED,
9029 PTR_TO_BTF_ID | PTR_TRUSTED,
9036 PTR_TO_BTF_ID | MEM_ALLOC,
9047 PTR_TO_BTF_ID,
9048 PTR_TO_BTF_ID | PTR_TRUSTED,
9049 PTR_TO_BTF_ID | MEM_RCU,
9054 PTR_TO_BTF_ID | MEM_PERCPU,
9055 PTR_TO_BTF_ID | MEM_PERCPU | MEM_RCU,
9056 PTR_TO_BTF_ID | MEM_PERCPU | PTR_TRUSTED,
9066 PTR_TO_BTF_ID | MEM_ALLOC
9159 if (base_type(reg->type) != PTR_TO_BTF_ID) in check_reg_type()
9174 case PTR_TO_BTF_ID: in check_reg_type()
9175 case PTR_TO_BTF_ID | PTR_TRUSTED: in check_reg_type()
9176 case PTR_TO_BTF_ID | PTR_TRUSTED | PTR_MAYBE_NULL: in check_reg_type()
9177 case PTR_TO_BTF_ID | MEM_RCU: in check_reg_type()
9178 case PTR_TO_BTF_ID | PTR_MAYBE_NULL: in check_reg_type()
9179 case PTR_TO_BTF_ID | PTR_MAYBE_NULL | MEM_RCU: in check_reg_type()
9224 case PTR_TO_BTF_ID | MEM_ALLOC: in check_reg_type()
9225 case PTR_TO_BTF_ID | MEM_PERCPU | MEM_ALLOC: in check_reg_type()
9237 case PTR_TO_BTF_ID | MEM_PERCPU: in check_reg_type()
9238 case PTR_TO_BTF_ID | MEM_PERCPU | MEM_RCU: in check_reg_type()
9239 case PTR_TO_BTF_ID | MEM_PERCPU | PTR_TRUSTED: in check_reg_type()
9318 case PTR_TO_BTF_ID: in check_func_arg_reg_off()
9319 case PTR_TO_BTF_ID | MEM_ALLOC: in check_func_arg_reg_off()
9320 case PTR_TO_BTF_ID | PTR_TRUSTED: in check_func_arg_reg_off()
9321 case PTR_TO_BTF_ID | MEM_RCU: in check_func_arg_reg_off()
9322 case PTR_TO_BTF_ID | MEM_ALLOC | NON_OWN_REF: in check_func_arg_reg_off()
9323 case PTR_TO_BTF_ID | MEM_ALLOC | NON_OWN_REF | MEM_RCU: in check_func_arg_reg_off()
10727 callee->regs[BPF_REG_2].type = PTR_TO_BTF_ID; in set_find_vma_callback_state()
11634 regs[BPF_REG_0].type = PTR_TO_BTF_ID | MEM_ALLOC | MEM_RCU; in check_helper_call()
11642 regs[BPF_REG_0].type = PTR_TO_BTF_ID | ret_flag; in check_helper_call()
11656 regs[BPF_REG_0].type = PTR_TO_BTF_ID | ret_flag; in check_helper_call()
12293 if ((base_type(reg->type) == PTR_TO_BTF_ID || reg2btf_ids[base_type(reg->type)])) { in get_kfunc_ptr_arg_type()
12339 if (base_type(reg->type) == PTR_TO_BTF_ID) { in process_kf_arg_ptr_to_btf_id()
12558 case PTR_TO_BTF_ID | MEM_ALLOC: in check_reg_allocation_locked()
13077 if (reg->type == (PTR_TO_BTF_ID | MEM_ALLOC)) { in check_kfunc_args()
13082 } else if (reg->type == (PTR_TO_BTF_ID | MEM_ALLOC | MEM_PERCPU)) { in check_kfunc_args()
13163 reg->type != (PTR_TO_BTF_ID | MEM_ALLOC)) { in check_kfunc_args()
13167 if (reg->type == (PTR_TO_BTF_ID | MEM_ALLOC) && !reg->ref_obj_id) { in check_kfunc_args()
13177 reg->type != (PTR_TO_BTF_ID | MEM_ALLOC)) { in check_kfunc_args()
13181 if (reg->type == (PTR_TO_BTF_ID | MEM_ALLOC) && !reg->ref_obj_id) { in check_kfunc_args()
13190 if (reg->type != (PTR_TO_BTF_ID | MEM_ALLOC)) { in check_kfunc_args()
13213 if (reg->type != (PTR_TO_BTF_ID | MEM_ALLOC)) { in check_kfunc_args()
13235 if ((base_type(reg->type) != PTR_TO_BTF_ID || in check_kfunc_args()
13351 if (reg->type != PTR_TO_MAP_VALUE && reg->type != (PTR_TO_BTF_ID | MEM_ALLOC)) { in check_kfunc_args()
13731 regs[BPF_REG_0].type = PTR_TO_BTF_ID | MEM_ALLOC; in check_kfunc_call()
13741 regs[BPF_REG_0].type = PTR_TO_BTF_ID | MEM_ALLOC; in check_kfunc_call()
13760 regs[BPF_REG_0].type = PTR_TO_BTF_ID | PTR_TRUSTED; in check_kfunc_call()
13772 regs[BPF_REG_0].type = PTR_TO_BTF_ID | PTR_UNTRUSTED; in check_kfunc_call()
13852 regs[BPF_REG_0].type = PTR_TO_BTF_ID; in check_kfunc_call()
14337 case PTR_TO_BTF_ID: in adjust_ptr_min_max_vals()
16561 base_type(src_reg->type) != PTR_TO_BTF_ID && in check_cond_jmp_op()
16562 base_type(dst_reg->type) != PTR_TO_BTF_ID) { in check_cond_jmp_op()
16652 case PTR_TO_BTF_ID: in check_ld_imm()
19328 case PTR_TO_BTF_ID: in reg_type_mismatch_ok()
19374 base_type(type) == PTR_TO_BTF_ID && in save_aux_ptr_type()
19375 base_type(*prev_type) == PTR_TO_BTF_ID) { in save_aux_ptr_type()
19382 *prev_type = PTR_TO_BTF_ID | PTR_UNTRUSTED; in save_aux_ptr_type()
19828 aux->btf_var.reg_type = PTR_TO_BTF_ID | MEM_PERCPU; in __check_pseudo_btf_id()
19847 aux->btf_var.reg_type = PTR_TO_BTF_ID; in __check_pseudo_btf_id()
20909 case PTR_TO_BTF_ID: in convert_ctx_accesses()
20910 case PTR_TO_BTF_ID | PTR_UNTRUSTED: in convert_ctx_accesses()
20917 case PTR_TO_BTF_ID | MEM_ALLOC | PTR_UNTRUSTED: in convert_ctx_accesses()
22732 reg->type = PTR_TO_BTF_ID; in do_check_common()