mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-01 03:11:59 +00:00
bpf: Move lnode list node to struct bpf_ksym
Adding lnode list node to 'struct bpf_ksym' object, so the struct bpf_ksym itself can be chained and used in other objects like bpf_trampoline and bpf_dispatcher. Changing iterator to bpf_ksym in bpf_get_kallsym function. The ksym->start is holding the prog->bpf_func value, so it's ok to use it as value in bpf_get_kallsym. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Song Liu <songliubraving@fb.com> Link: https://lore.kernel.org/bpf/20200312195610.346362-6-jolsa@kernel.org Signed-off-by: Alexei Starovoitov <ast@kernel.org>
This commit is contained in:
parent
bfea9a8574
commit
ecb60d1c67
2 changed files with 12 additions and 12 deletions
|
@ -476,6 +476,7 @@ struct bpf_ksym {
|
|||
unsigned long start;
|
||||
unsigned long end;
|
||||
char name[KSYM_NAME_LEN];
|
||||
struct list_head lnode;
|
||||
};
|
||||
|
||||
enum bpf_tramp_prog_type {
|
||||
|
@ -659,7 +660,6 @@ struct bpf_prog_aux {
|
|||
struct bpf_jit_poke_descriptor *poke_tab;
|
||||
u32 size_poke_tab;
|
||||
struct latch_tree_node ksym_tnode;
|
||||
struct list_head ksym_lnode;
|
||||
struct bpf_ksym ksym;
|
||||
const struct bpf_prog_ops *ops;
|
||||
struct bpf_map **used_maps;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue