Function report |
Source Code:kernel\bpf\cgroup.c |
Create Date:2022-07-28 13:28:57 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:sysctl_convert_ctx_access
Proto:static u32 sysctl_convert_ctx_access(enum bpf_access_type type, const struct bpf_insn *si, struct bpf_insn *insn_buf, struct bpf_prog *prog, u32 *target_size)
Type:u32
Parameter:
Type | Parameter | Name |
---|---|---|
enum bpf_access_type | type | |
const struct bpf_insn * | si | |
struct bpf_insn * | insn_buf | |
struct bpf_prog * | prog | |
u32 * | target_size |
1347 | Case signed offset == offsetof(structbpf_sysctl, write) |
1354 | Break |
1355 | Case signed offset == offsetof(structbpf_sysctl, file_pos) |
1364 | If source register == treg || dest register == treg Then --treg |
1366 | If source register == treg || dest register == treg Then --treg |
1368 | insn++ = Memory store, *(uint *) (dst_reg + off16) = src_reg (double word (64-bit) , dest register , treg, offsetof(structbpf_sysctl_kern, tmp_reg)) |
1371 | insn++ = Memory load, dst_reg = *(uint *) (src_reg + off16) (BPF_FIELD_SIZEOF(structbpf_sysctl_kern, ppos), treg, dest register , offsetof(structbpf_sysctl_kern, ppos)) |
1375 | insn++ = Memory store, *(uint *) (dst_reg + off16) = src_reg (BPF_SIZEOF(u32), treg, source register , bpf_ctx_narrow_access_offset(0, sizeof(u32), sizeof(loff_t))) |
1379 | insn++ = Memory load, dst_reg = *(uint *) (src_reg + off16) (double word (64-bit) , treg, dest register , offsetof(structbpf_sysctl_kern, tmp_reg)) |
1382 | Else |
1383 | insn++ = Memory load, dst_reg = *(uint *) (src_reg + off16) (BPF_FIELD_SIZEOF(structbpf_sysctl_kern, ppos), dest register , source register , offsetof(structbpf_sysctl_kern, ppos)) |
1387 | read_size = bpf_size_to_bytes(ld/ldx fields ( opcode )) |
1393 | target_size = sizeof(u32) |
1394 | Break |
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 |