函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\bpf\verifier.c Create Date:2022-07-27 14:13:33
Last Modify:2022-05-19 20:02:10 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:prepare_func_exit

函数原型:static int prepare_func_exit(struct bpf_verifier_env *env, int *insn_idx)

返回类型:int

参数:

类型参数名称
struct bpf_verifier_env *env
int *insn_idx
4028  state等于current verifier state
4033  callee等于 call stack tracking [curframe]
4034  r0等于regs[BPF_REG_0]
4035  如果 Ordering of fields matters. See states_equal() 恒等于g == frame_pointer + offset
4042  verbose(env, "cannot return stack pointer to the caller\n")
4043  返回:负EINVAL
4046  curframe自减
4047  caller等于 call stack tracking [curframe]
4049  regs[BPF_REG_0]等于r0
4052  err等于transfer_reference_state(caller, callee)
4053  如果err则返回:err
4056  insn_idx等于dex of call instruction that called into this func 加1
4057  如果level按位与BPF_LOG_LEVEL
4058  verbose(env, "returning from callee:\n")
4059  print_verifier_state(env, callee)
4060  verbose(env, "to caller at %d:\n", * insn_idx)
4061  print_verifier_state(env, caller)
4064  free_func_state(callee)
4065  call stack tracking [curframe + 1] = NULL
4066  返回:0
调用者
名称描述
do_check