aboutsummaryrefslogtreecommitdiffstats
path: root/tools/include/uapi/linux/bpf.h
diff options
context:
space:
mode:
Diffstat (limited to 'tools/include/uapi/linux/bpf.h')
-rw-r--r--tools/include/uapi/linux/bpf.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/tools/include/uapi/linux/bpf.h b/tools/include/uapi/linux/bpf.h
index 56bf493ba7ed..7f7fbb9d0253 100644
--- a/tools/include/uapi/linux/bpf.h
+++ b/tools/include/uapi/linux/bpf.h
@@ -95,6 +95,7 @@ enum bpf_cmd {
95 BPF_OBJ_GET_INFO_BY_FD, 95 BPF_OBJ_GET_INFO_BY_FD,
96 BPF_PROG_QUERY, 96 BPF_PROG_QUERY,
97 BPF_RAW_TRACEPOINT_OPEN, 97 BPF_RAW_TRACEPOINT_OPEN,
98 BPF_BTF_LOAD,
98}; 99};
99 100
100enum bpf_map_type { 101enum bpf_map_type {
@@ -279,6 +280,9 @@ union bpf_attr {
279 */ 280 */
280 char map_name[BPF_OBJ_NAME_LEN]; 281 char map_name[BPF_OBJ_NAME_LEN];
281 __u32 map_ifindex; /* ifindex of netdev to create on */ 282 __u32 map_ifindex; /* ifindex of netdev to create on */
283 __u32 btf_fd; /* fd pointing to a BTF type data */
284 __u32 btf_key_id; /* BTF type_id of the key */
285 __u32 btf_value_id; /* BTF type_id of the value */
282 }; 286 };
283 287
284 struct { /* anonymous struct used by BPF_MAP_*_ELEM commands */ 288 struct { /* anonymous struct used by BPF_MAP_*_ELEM commands */
@@ -363,6 +367,14 @@ union bpf_attr {
363 __u64 name; 367 __u64 name;
364 __u32 prog_fd; 368 __u32 prog_fd;
365 } raw_tracepoint; 369 } raw_tracepoint;
370
371 struct { /* anonymous struct for BPF_BTF_LOAD */
372 __aligned_u64 btf;
373 __aligned_u64 btf_log_buf;
374 __u32 btf_size;
375 __u32 btf_log_size;
376 __u32 btf_log_level;
377 };
366} __attribute__((aligned(8))); 378} __attribute__((aligned(8)));
367 379
368/* BPF helper function descriptions: 380/* BPF helper function descriptions: