Thread (1 message) 1 message, 1 author, 2018-07-03

Re: [PATCH bpf-next v2 1/3] bpf: btf: export btf types and name by offset from lib

From: Jakub Kicinski <hidden>
Date: 2018-07-03 04:07:39
Also in: lkml

On Mon, 2 Jul 2018 11:39:14 -0700, Okash Khawaja wrote:
quoted hunk
--- a/tools/lib/bpf/btf.h
+++ b/tools/lib/bpf/btf.h
@@ -17,6 +17,9 @@ void btf__free(struct btf *btf);
 struct btf *btf__new(uint8_t *data, uint32_t size, btf_print_fn_t err_log);
 int32_t btf__find_by_name(const struct btf *btf, const char *type_name);
 int64_t btf__resolve_size(const struct btf *btf, uint32_t type_id);
+int32_t btf__resolve_type(const struct btf *btf, uint32_t type_id);
 int btf__fd(const struct btf *btf);
+const char *btf__name_by_offset(const struct btf *btf, uint32_t offset);
+const struct btf_type *btf__type_by_id(const struct btf *btf, uint32_t type_id);
Why is BTF code using stdint types?  libbpf used to follow the kernel
coding style AFA int types go.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help