• Home
  • Raw
  • Download

Lines Matching refs:st

172 	struct bpf_verifier_state st;  member
1242 static void update_branch_counts(struct bpf_verifier_env *env, struct bpf_verifier_state *st) in update_branch_counts() argument
1244 while (st) { in update_branch_counts()
1245 u32 br = --st->branches; in update_branch_counts()
1255 st = st->parent; in update_branch_counts()
1270 err = copy_verifier_state(cur, &head->st); in pop_stack()
1281 free_verifier_state(&head->st, false); in pop_stack()
1306 err = copy_verifier_state(&elem->st, cur); in push_stack()
1309 elem->st.speculative |= speculative; in push_stack()
1315 if (elem->st.parent) { in push_stack()
1316 ++elem->st.parent->branches; in push_stack()
1327 return &elem->st; in push_stack()
1821 elem->st.branches = 1; in push_async_cb()
1829 elem->st.frame[0] = frame; in push_async_cb()
1830 return &elem->st; in push_async_cb()
2548 static int get_prev_insn_idx(struct bpf_verifier_state *st, int i, in get_prev_insn_idx() argument
2553 if (i == st->first_insn_idx) { in get_prev_insn_idx()
2556 if (cnt == 1 && st->jmp_history[0].idx == i) in get_prev_insn_idx()
2560 if (cnt && st->jmp_history[cnt - 1].idx == i) { in get_prev_insn_idx()
2561 i = st->jmp_history[cnt - 1].prev_idx; in get_prev_insn_idx()
2806 struct bpf_verifier_state *st) in mark_all_scalars_precise() argument
2818 for (st = st->parent; st; st = st->parent) { in mark_all_scalars_precise()
2819 for (i = 0; i <= st->curframe; i++) { in mark_all_scalars_precise()
2820 func = st->frame[i]; in mark_all_scalars_precise()
2839 static void mark_all_scalars_imprecise(struct bpf_verifier_env *env, struct bpf_verifier_state *st) in mark_all_scalars_imprecise() argument
2845 for (i = 0; i <= st->curframe; i++) { in mark_all_scalars_imprecise()
2846 func = st->frame[i]; in mark_all_scalars_imprecise()
2954 struct bpf_verifier_state *st = env->cur_state; in __mark_chain_precision() local
2955 int first_idx = st->first_insn_idx; in __mark_chain_precision()
2972 func = st->frame[frame]; in __mark_chain_precision()
3003 u32 history = st->jmp_history_cnt; in __mark_chain_precision()
3014 if (st->curframe == 0 && in __mark_chain_precision()
3015 st->frame[0]->subprogno > 0 && in __mark_chain_precision()
3016 st->frame[0]->callsite == BPF_MAIN_FUNC && in __mark_chain_precision()
3020 reg = &st->frame[0]->regs[i]; in __mark_chain_precision()
3031 st->frame[0]->subprogno, reg_mask, stack_mask); in __mark_chain_precision()
3044 mark_all_scalars_precise(env, st); in __mark_chain_precision()
3055 i = get_prev_insn_idx(st, i, &history); in __mark_chain_precision()
3070 st = st->parent; in __mark_chain_precision()
3071 if (!st) in __mark_chain_precision()
3075 func = st->frame[frame]; in __mark_chain_precision()
3104 mark_all_scalars_precise(env, st); in __mark_chain_precision()
3133 last_idx = st->last_insn_idx; in __mark_chain_precision()
3134 first_idx = st->first_insn_idx; in __mark_chain_precision()
11691 struct bpf_func_state *st) in clean_func_state() argument
11697 live = st->regs[i].live; in clean_func_state()
11699 st->regs[i].live |= REG_LIVE_DONE; in clean_func_state()
11704 __mark_reg_not_init(env, &st->regs[i]); in clean_func_state()
11707 for (i = 0; i < st->allocated_stack / BPF_REG_SIZE; i++) { in clean_func_state()
11708 live = st->stack[i].spilled_ptr.live; in clean_func_state()
11710 st->stack[i].spilled_ptr.live |= REG_LIVE_DONE; in clean_func_state()
11712 __mark_reg_not_init(env, &st->stack[i].spilled_ptr); in clean_func_state()
11714 st->stack[i].slot_type[j] = STACK_INVALID; in clean_func_state()
11720 struct bpf_verifier_state *st) in clean_verifier_state() argument
11724 if (st->frame[0]->regs[0].live & REG_LIVE_DONE) in clean_verifier_state()
11728 for (i = 0; i <= st->curframe; i++) in clean_verifier_state()
11729 clean_func_state(env, st->frame[i]); in clean_verifier_state()