diff options
author | Hengqi Chen <hengqi.chen@gmail.com> | 2021-10-03 18:58:44 +0200 |
---|---|---|
committer | Andrii Nakryiko <andrii@kernel.org> | 2021-10-06 21:34:02 +0200 |
commit | 6f2b219b62a4376ca2da15c503de79d0650c8155 (patch) | |
tree | d6b57e0ba51373477c58bea70ec99e43e553913e /tools/bpf/bpftool/iter.c | |
parent | libbpf: Deprecate bpf_{map,program}__{prev,next} APIs since v0.7 (diff) | |
download | linux-6f2b219b62a4376ca2da15c503de79d0650c8155.tar.xz linux-6f2b219b62a4376ca2da15c503de79d0650c8155.zip |
selftests/bpf: Switch to new bpf_object__next_{map,program} APIs
Replace deprecated bpf_{map,program}__next APIs with newly added
bpf_object__next_{map,program} APIs, so that no compilation warnings
emit.
Signed-off-by: Hengqi Chen <hengqi.chen@gmail.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Acked-by: Song Liu <songliubraving@fb.com>
Link: https://lore.kernel.org/bpf/20211003165844.4054931-3-hengqi.chen@gmail.com
Diffstat (limited to 'tools/bpf/bpftool/iter.c')
-rw-r--r-- | tools/bpf/bpftool/iter.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/bpf/bpftool/iter.c b/tools/bpf/bpftool/iter.c index 84a9b01d956d..6c0de647b8ad 100644 --- a/tools/bpf/bpftool/iter.c +++ b/tools/bpf/bpftool/iter.c @@ -57,7 +57,7 @@ static int do_pin(int argc, char **argv) goto close_obj; } - prog = bpf_program__next(NULL, obj); + prog = bpf_object__next_program(obj, NULL); if (!prog) { p_err("can't find bpf program in objfile %s", objfile); goto close_obj; |