Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\bpf\btf.c Create Date:2022-07-28 13:18:37
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:btf_var_resolve

Proto:static int btf_var_resolve(struct btf_verifier_env *env, const struct resolve_vertex *v)

Type:int

Parameter:

TypeParameterName
struct btf_verifier_env *env
const struct resolve_vertex *v
1725  t = t
1726  next_type_id = type
1727  btf = btf
1729  next_type = btf_type_by_id(btf, next_type_id)
1730  If Not next_type || Types that act only as a source, not sink or intermediate* type when resolving. Then
1731  btf_verifier_log_type(env, t, "Invalid type_id")
1732  Return -EINVAL
1735  If Not env_type_is_resolve_sink(env, next_type) && Not env_type_is_resolved(env, next_type_id) Then Return env_stack_push(env, next_type, next_type_id)
1739  If btf_type_is_modifier(next_type) Then
1743  resolved_type_id = next_type_id
1744  resolved_type = The input param "type_id" must point to a needs_resolve type
1746  If btf_type_is_ptr(resolved_type) && Not env_type_is_resolve_sink(env, resolved_type) && Not env_type_is_resolved(env, resolved_type_id) Then Return env_stack_push(env, resolved_type, resolved_type_id)
1757  If Not btf_type_id_size(btf, & next_type_id, NULL) Then
1758  btf_verifier_log_type(env, t, "Invalid type_id")
1759  Return -EINVAL
1762  env_stack_pop_resolved(env, next_type_id, 0)
1764  Return 0