函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\bpf\core.c Create Date:2022-07-27 13:59:16
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:bpf_prog_alloc_no_stats

函数原型:struct bpf_prog *bpf_prog_alloc_no_stats(unsigned int size, gfp_t gfp_extra_flags)

返回类型:struct bpf_prog

参数:

类型参数名称
unsigned intsize
gfp_tgfp_extra_flags
80  gfp_flags等于GFP_KERNEL按位或__GFP_ZERO按位或gfp_extra_flags
84  size等于und_up - round up to next specified power of 2*@x: the value to round*@y: multiple to round up to (must be a power of 2)* Rounds @x up to next multiple of @y (which must be a power of 2).* To perform arbitrary rounding up, use roundup() below.(size, PAGE_SIZE)
85  fp等于__vmalloc(size, gfp_flags, PAGE_KERNEL)
86  如果(fp == NULL)则返回:NULL
89  aux等于分配内存并置零
90  如果(aux == NULL)则
91  vfree(fp)
92  返回:NULL
95  Number of allocated pages 等于sizePAGE_SIZE
96  Auxiliary fields 等于aux
97  prog等于fp
98  archs need to JIT the prog 等于ebpf_jit_enabled()
100  INIT_LIST_HEAD_RCU - Initialize a list_head visible to RCU readers*@list: list to be initialized* You should instead use INIT_LIST_HEAD() for normal initialization and* cleanup tasks, when readers have no access to the list being initialized
102  返回:fp
调用者
名称描述
bpf_prog_alloc
jit_subprogs