Function report |
Source Code:kernel\bpf\cgroup.c |
Create Date:2022-07-28 13:27:23 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:mpute a chain of effective programs for a given cgroup:* start from the list of programs in this cgroup and add* all parent programs.* Note that parent's F_ALLOW_OVERRIDE-type program is yielding* to programs in this cgroup
Proto:static int compute_effective_progs(struct cgroup *cgrp, enum bpf_attach_type type, struct bpf_prog_array **array)
Type:int
Parameter:
Type | Parameter | Name |
---|---|---|
struct cgroup * | cgrp | |
enum bpf_attach_type | type | |
struct bpf_prog_array ** | array |
146 | cnt = 0 |
149 | Do |
150 | If cnt == 0 || flags[type] & BPF_F_ALLOW_MULTI Then cnt += number of elements in the list.* it's slow but the list cannot be long |
152 | p = cgroup_parent(p) |
155 | progs = bpf_prog_array_alloc(cnt, GFP_KERNEL) |
160 | cnt = 0 |
162 | Do |
163 | If cnt > 0 && Not (flags[type] & BPF_F_ALLOW_MULTI) Then Continue |
167 | If Not prog Then Continue |
172 | cgroup_storage[stype] = storage[stype] |
174 | cnt++ |
176 | When p = cgroup_parent(p) cycle |
179 | Return 0 |
Name | Describe |
---|---|
cgroup_bpf_inherit | group_bpf_inherit() - inherit effective programs from parent*@cgrp: the cgroup to modify |
update_effective_progs |
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 |