summaryrefslogtreecommitdiff
path: root/tools/lib/bpf/bpf.h
diff options
context:
space:
mode:
authorYonghong Song <yhs@fb.com>2018-11-19 15:29:14 -0800
committerAlexei Starovoitov <ast@kernel.org>2018-11-20 10:54:39 -0800
commit7e0d0fb5522a388700ceff723af98c47ffa8a0a9 (patch)
treed2e6a0de7257b79ef093f31e4d52e7fa368b8b54 /tools/lib/bpf/bpf.h
parentcc19435cb2ee34a3663f0be69f3a4647795b0417 (diff)
downloadlwn-7e0d0fb5522a388700ceff723af98c47ffa8a0a9.tar.gz
lwn-7e0d0fb5522a388700ceff723af98c47ffa8a0a9.zip
tools/bpf: add new fields for program load in lib/bpf
The new fields are added for program load in lib/bpf so application uses api bpf_load_program_xattr() is able to load program with btf and func_info data. This functionality will be used in next patch by bpf selftest test_btf. 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 'tools/lib/bpf/bpf.h')
-rw-r--r--tools/lib/bpf/bpf.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/lib/bpf/bpf.h b/tools/lib/bpf/bpf.h
index 26a51538213c..8bdfd806253a 100644
--- a/tools/lib/bpf/bpf.h
+++ b/tools/lib/bpf/bpf.h
@@ -74,6 +74,10 @@ struct bpf_load_program_attr {
const char *license;
__u32 kern_version;
__u32 prog_ifindex;
+ __u32 prog_btf_fd;
+ __u32 func_info_rec_size;
+ const void *func_info;
+ __u32 func_info_cnt;
};
/* Flags to direct loading requirements */