aboutsummaryrefslogtreecommitdiffstats
path: root/include/uapi/linux
diff options
context:
space:
mode:
authorMartin KaFai Lau <kafai@fb.com>2018-05-22 17:57:21 -0400
committerDaniel Borkmann <daniel@iogearbox.net>2018-05-23 06:03:32 -0400
commit9b2cf328b2eccf761537a06bef914d2a0700fba7 (patch)
tree136dc187e3f62e0becbe0a5c8271e02fe522696d /include/uapi/linux
parentaea2f7b8911617d7a8c23fb73d69e78764f91b58 (diff)
bpf: btf: Rename btf_key_id and btf_value_id in bpf_map_info
In "struct bpf_map_info", the name "btf_id", "btf_key_id" and "btf_value_id" could cause confusion because the "id" of "btf_id" means the BPF obj id given to the BTF object while "btf_key_id" and "btf_value_id" means the BTF type id within that BTF object. To make it clear, btf_key_id and btf_value_id are renamed to btf_key_type_id and btf_value_type_id. Suggested-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: Martin KaFai Lau <kafai@fb.com> Acked-by: Yonghong Song <yhs@fb.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Diffstat (limited to 'include/uapi/linux')
-rw-r--r--include/uapi/linux/bpf.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/uapi/linux/bpf.h b/include/uapi/linux/bpf.h
index 97446bbe2ca5..c3e502d06bc3 100644
--- a/include/uapi/linux/bpf.h
+++ b/include/uapi/linux/bpf.h
@@ -284,8 +284,8 @@ union bpf_attr {
284 char map_name[BPF_OBJ_NAME_LEN]; 284 char map_name[BPF_OBJ_NAME_LEN];
285 __u32 map_ifindex; /* ifindex of netdev to create on */ 285 __u32 map_ifindex; /* ifindex of netdev to create on */
286 __u32 btf_fd; /* fd pointing to a BTF type data */ 286 __u32 btf_fd; /* fd pointing to a BTF type data */
287 __u32 btf_key_id; /* BTF type_id of the key */ 287 __u32 btf_key_type_id; /* BTF type_id of the key */
288 __u32 btf_value_id; /* BTF type_id of the value */ 288 __u32 btf_value_type_id; /* BTF type_id of the value */
289 }; 289 };
290 290
291 struct { /* anonymous struct used by BPF_MAP_*_ELEM commands */ 291 struct { /* anonymous struct used by BPF_MAP_*_ELEM commands */
@@ -2219,8 +2219,8 @@ struct bpf_map_info {
2219 __u64 netns_dev; 2219 __u64 netns_dev;
2220 __u64 netns_ino; 2220 __u64 netns_ino;
2221 __u32 btf_id; 2221 __u32 btf_id;
2222 __u32 btf_key_id; 2222 __u32 btf_key_type_id;
2223 __u32 btf_value_id; 2223 __u32 btf_value_type_id;
2224} __attribute__((aligned(8))); 2224} __attribute__((aligned(8)));
2225 2225
2226struct bpf_btf_info { 2226struct bpf_btf_info {