diff options
author | Taeung Song <treeze.taeung@gmail.com> | 2018-09-02 19:30:07 -0400 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2018-09-06 01:16:00 -0400 |
commit | 69495d2a52957c415d11312fe37844062a48fd32 (patch) | |
tree | 620ec864435dcee2bace37d2b233fec44848ad1d /tools/lib/bpf | |
parent | 428f944bd58607021b5a1f85d145c0b50f908c6f (diff) |
libbpf: Remove the duplicate checking of function storage
After the commit eac7d84519a3 ("tools: libbpf: don't return '.text'
as a program for multi-function programs"), bpf_program__next()
in bpf_object__for_each_program skips the function storage such as .text,
so eliminate the duplicate checking.
Cc: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: Taeung Song <treeze.taeung@gmail.com>
Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'tools/lib/bpf')
-rw-r--r-- | tools/lib/bpf/libbpf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/lib/bpf/libbpf.c b/tools/lib/bpf/libbpf.c index 2abd0f112627..8476da7f2720 100644 --- a/tools/lib/bpf/libbpf.c +++ b/tools/lib/bpf/libbpf.c | |||
@@ -2336,7 +2336,7 @@ int bpf_prog_load_xattr(const struct bpf_prog_load_attr *attr, | |||
2336 | bpf_program__set_expected_attach_type(prog, | 2336 | bpf_program__set_expected_attach_type(prog, |
2337 | expected_attach_type); | 2337 | expected_attach_type); |
2338 | 2338 | ||
2339 | if (!bpf_program__is_function_storage(prog, obj) && !first_prog) | 2339 | if (!first_prog) |
2340 | first_prog = prog; | 2340 | first_prog = prog; |
2341 | } | 2341 | } |
2342 | 2342 | ||