]> granicus.if.org Git - strace/commit
bpf: add support for btf_* fields in BPF_MAP_CREATE
authorDmitry V. Levin <ldv@altlinux.org>
Tue, 12 Mar 2019 11:17:20 +0000 (11:17 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Tue, 12 Mar 2019 11:17:20 +0000 (11:17 +0000)
commit14a9b6ca66109fc1231eb16e98a9ce4262fb610c
tree9b67dadea04364bb18b8151d007d0e95377dfa78
parentcabd6955d3c3048bb2ba19032b504eeb3776a86f
bpf: add support for btf_* fields in BPF_MAP_CREATE

* bpf_attr.h (struct BPF_MAP_CREATE_struct): Add btf_fd,
btf_key_type_id, and btf_value_type_id fields.
* bpf.c (BEGIN_BPF_CMD_DECODER(BPF_MAP_CREATE)): Decode btf_fd,
btf_key_type_id, and btf_value_type_id fields introduced by Linux
commits v4.18-rc1~114^2~417^2~1^2~3 and v4.18-rc1~114^2~148^2~7^2~2.
* tests/bpf.c (BPF_MAP_CREATE_checks): Check it.
* tests/bpf-obj_get_info_by_fd.c (print_map_create): Update expected
output.
bpf.c
bpf_attr.h
tests/bpf-obj_get_info_by_fd.c
tests/bpf.c