Function report |
Source Code:lib\test_bpf.c |
Create Date:2022-07-28 06:26:56 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:bpf_fill_maxinsns9
Proto:static int bpf_fill_maxinsns9(struct bpf_test *self)
Type:int
Parameter:
| Type | Parameter | Name |
|---|---|---|
| struct bpf_test * | self |
| 268 | len = BPF_MAXINSNS |
| 272 | insn = kmalloc_array - allocate memory for an array.*@n: number of elements.*@size: element size.*@flags: the type of memory to allocate (see kmalloc). |
| 276 | insn[0] = Conditional jumps against immediates, if (dst_reg 'op' imm32) goto pc + off16 (BPF_JA, 0, 0, len - 2) |
| 277 | insn[1] = BPF_ALU32_IMM(mov reg to reg , Redefine REGs to make tests less verbose , 0xcbababab) |
| 278 | insn[2] = Program exit () |
| 280 | When i < len - 2 cycle insn[i] = BPF_ALU32_IMM(mov reg to reg , Redefine REGs to make tests less verbose , 0xfefefefe) |
| 283 | insn[len - 2] = Program exit () |
| 284 | insn[len - 1] = Conditional jumps against immediates, if (dst_reg 'op' imm32) goto pc + off16 (BPF_JA, 0, 0, - (len - 1)) |
| 289 | Return 0 |
| Source code conversion tool public plug-in interface | X |
|---|---|
| Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |