diff options
| author | Puranjay Mohan <puranjay@kernel.org> | 2025-09-11 14:58:01 +0000 |
|---|---|---|
| committer | Alexei Starovoitov <ast@kernel.org> | 2025-09-11 13:00:43 -0700 |
| commit | 70f23546d246563da648baedbb0432ba1d6bb357 (patch) | |
| tree | fcbf3179be03afa2d03bf20200f7ee48b9f37e0d /rust/helpers/build_bug.c | |
| parent | 0460484244e1fa4a0cdbc9ed76c838fc528134d3 (diff) | |
bpf: core: introduce main_prog_aux for stream access
BPF streams are only valid for the main programs, to make it easier to
access streams from subprogs, introduce main_prog_aux in struct
bpf_prog_aux.
prog->aux->main_prog_aux = prog->aux, for main programs and
prog->aux->main_prog_aux = main_prog->aux, for subprograms.
Make bpf_prog_find_from_stack() use the added main_prog_aux to return
the mainprog when a subprog is found on the stack.
Signed-off-by: Puranjay Mohan <puranjay@kernel.org>
Acked-by: Eduard Zingerman <eddyz87@gmail.com>
Link: https://lore.kernel.org/r/20250911145808.58042-3-puranjay@kernel.org
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'rust/helpers/build_bug.c')
0 files changed, 0 insertions, 0 deletions
