aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/bpf/verifier
diff options
context:
space:
mode:
authorDaniel Borkmann <daniel@iogearbox.net>2019-04-09 23:20:15 +0200
committerAlexei Starovoitov <ast@kernel.org>2019-04-09 17:05:47 -0700
commit817998afa038c156bbc1a6e69c48aa26282cc41f (patch)
tree0b9dd4132343ed490f7162d3ab75690304b2f722 /tools/testing/selftests/bpf/verifier
parentbpf, libbpf: add support for BTF Var and DataSec (diff)
downloadlinux-dev-817998afa038c156bbc1a6e69c48aa26282cc41f.tar.xz
linux-dev-817998afa038c156bbc1a6e69c48aa26282cc41f.zip
bpf: bpftool support for dumping data/bss/rodata sections
Add the ability to bpftool to handle BTF Var and DataSec kinds in order to dump them out of btf_dumper_type(). The value has a single object with the section name, which itself holds an array of variables it dumps. A single variable is an object by itself printed along with its name. From there further type information is dumped along with corresponding value information. Example output from .rodata: # ./bpftool m d i 150 [{ "value": { ".rodata": [{ "load_static_data.bar": 18446744073709551615 },{ "num2": 24 },{ "num5": 43947 },{ "num6": 171 },{ "str0": [97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,0,0,0,0,0,0 ] },{ "struct0": { "a": 42, "b": 4278120431, "c": 1229782938247303441 } },{ "struct2": { "a": 0, "b": 0, "c": 0 } } ] } } ] Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Martin KaFai Lau <kafai@fb.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'tools/testing/selftests/bpf/verifier')
0 files changed, 0 insertions, 0 deletions