aboutsummaryrefslogtreecommitdiffstats
path: root/tools/include/uapi/linux/bpf.h
diff options
context:
space:
mode:
authorYonghong Song <yhs@fb.com>2018-11-19 15:29:13 -0800
committerAlexei Starovoitov <ast@kernel.org>2018-11-20 10:54:39 -0800
commitcc19435cb2ee34a3663f0be69f3a4647795b0417 (patch)
treed80eaef9e5b164d55ad33769a148f11ad12c0a70 /tools/include/uapi/linux/bpf.h
parentbpf: Introduce bpf_func_info (diff)
downloadlinux-dev-cc19435cb2ee34a3663f0be69f3a4647795b0417.tar.xz
linux-dev-cc19435cb2ee34a3663f0be69f3a4647795b0417.zip
tools/bpf: sync kernel uapi bpf.h header to tools directory
The kernel uapi bpf.h is synced to tools directory. Signed-off-by: Yonghong Song <yhs@fb.com> Signed-off-by: Martin KaFai Lau <kafai@fb.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to '')
-rw-r--r--tools/include/uapi/linux/bpf.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/tools/include/uapi/linux/bpf.h b/tools/include/uapi/linux/bpf.h
index 05d95290b848..c1554aa07465 100644
--- a/tools/include/uapi/linux/bpf.h
+++ b/tools/include/uapi/linux/bpf.h
@@ -338,6 +338,10 @@ union bpf_attr {
* (context accesses, allowed helpers, etc).
*/
__u32 expected_attach_type;
+ __u32 prog_btf_fd; /* fd pointing to BTF type data */
+ __u32 func_info_rec_size; /* userspace bpf_func_info size */
+ __aligned_u64 func_info; /* func info */
+ __u32 func_info_cnt; /* number of bpf_func_info records */
};
struct { /* anonymous struct used by BPF_OBJ_* commands */
@@ -2638,6 +2642,10 @@ struct bpf_prog_info {
__u32 nr_jited_func_lens;
__aligned_u64 jited_ksyms;
__aligned_u64 jited_func_lens;
+ __u32 btf_id;
+ __u32 func_info_rec_size;
+ __aligned_u64 func_info;
+ __u32 func_info_cnt;
} __attribute__((aligned(8)));
struct bpf_map_info {
@@ -2949,4 +2957,9 @@ struct bpf_flow_keys {
};
};
+struct bpf_func_info {
+ __u32 insn_offset;
+ __u32 type_id;
+};
+
#endif /* _UAPI__LINUX_BPF_H__ */