]> git.baikalelectronics.ru Git - kernel.git/commit
bpf: btf: Add pretty print capability for data with BTF type info
authorMartin KaFai Lau <kafai@fb.com>
Wed, 18 Apr 2018 22:56:00 +0000 (15:56 -0700)
committerDaniel Borkmann <daniel@iogearbox.net>
Thu, 19 Apr 2018 19:46:25 +0000 (21:46 +0200)
commit61662444ba2c293ab8d7375779f70bbbff64efdf
tree7b66e5f4fb01c891dcb0c62b2e7239efd912d66c
parentc70c57aa9b3af328af2add5d26800f050048137f
bpf: btf: Add pretty print capability for data with BTF type info

This patch adds pretty print capability for data with BTF type info.
The current usage is to allow pretty print for a BPF map.

The next few patches will allow a read() on a pinned map with BTF
type info for its key and value.

This patch uses the seq_printf() infra.

Signed-off-by: Martin KaFai Lau <kafai@fb.com>
Acked-by: Alexei Starovoitov <ast@fb.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
include/linux/btf.h
kernel/bpf/btf.c