kernel-fxtec-pro1x/tools/bpf/bpftool
Martin KaFai Lau 0d6f9d8f31 bpftool: Fix printing incorrect pointer in btf_dump_ptr
commit 555089fdfc37ad65e0ee9b42ca40c238ff546f83 upstream.

For plain text output, it incorrectly prints the pointer value
"void *data".  The "void *data" is actually pointing to memory that
contains a bpf-map's value.  The intention is to print the content of
the bpf-map's value instead of printing the pointer pointing to the
bpf-map's value.

In this case, a member of the bpf-map's value is a pointer type.
Thus, it should print the "*(void **)data".

Fixes: 22c349e8db89 ("tools: bpftool: fix format strings and arguments for jsonw_printf()")
Signed-off-by: Martin KaFai Lau <kafai@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Reviewed-by: Quentin Monnet <quentin.monnet@netronome.com>
Link: https://lore.kernel.org/bpf/20200110231644.3484151-1-kafai@fb.com
Cc: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-04-29 16:31:07 +02:00
..
bash-completion tools: bpftool: fix completion for "bpftool map update" 2019-12-01 09:16:47 +01:00
Documentation tools: bpf: build and install man page for eBPF helpers from bpftool/ 2018-07-12 18:55:53 +02:00
.gitignore bpftool: exclude bash-completion/bpftool from .gitignore pattern 2019-05-31 06:46:08 -07:00
btf_dumper.c bpftool: Fix printing incorrect pointer in btf_dump_ptr 2020-04-29 16:31:07 +02:00
cfg.c tools: bpftool: generate .dot graph from CFG information 2018-03-01 18:29:49 -08:00
cfg.h tools: bpftool: detect sub-programs from the eBPF sequence 2018-03-01 18:29:48 -08:00
cgroup.c tools: bpftool: use correct argument in cgroup errors 2020-01-27 14:50:58 +01:00
common.c tools: bpftool: pass an argument to silence open_obj_pinned() 2019-12-01 09:17:31 +01:00
jit_disasm.c tools: bpftool: Fix json dump crash on powerpc 2019-07-26 09:14:16 +02:00
json_writer.c tools: bpftool: add JSON output for bpftool prog dump xlated * command 2017-10-24 01:25:08 +01:00
json_writer.h tools: bpftool: add JSON output for bpftool prog dump xlated * command 2017-10-24 01:25:08 +01:00
main.c tools: bpftool: drop unnecessary Author comments 2018-07-01 01:01:50 +02:00
main.h tools: bpftool: pass an argument to silence open_obj_pinned() 2019-12-01 09:17:31 +01:00
Makefile tools: bpftool: don't pass FEATURES_DUMP to libbpf 2018-07-16 16:36:57 -07:00
map.c bpftool: fix percpu maps updating 2019-03-13 14:02:34 -07:00
map_perf_ring.c tools: bpftool: fix arguments for p_err() in do_event_pipe() 2020-01-27 14:51:04 +01:00
perf.c tools/bpftool: fix a bug in bpftool perf 2018-06-13 02:03:17 +02:00
prog.c tools: bpftool: close prog FD before exit on showing a single program 2019-09-21 07:16:52 +02:00
xlated_dumper.c tools: bpf: make use of reallocarray 2018-07-11 22:13:34 +02:00
xlated_dumper.h tools: bpftool: add delimiters to multi-function JITed dumps 2018-05-24 09:20:50 +02:00