New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bpf: add support for BTF_KIND_DECL_TAG typedef #1974
Conversation
Master branch: db5b6a4 |
Master branch: 44ce0ac |
9e2d175
to
f636c44
Compare
Master branch: 549beec |
f636c44
to
72aad4e
Compare
Master branch: b0c7663 |
72aad4e
to
44f77aa
Compare
Master branch: 29da17c |
44f77aa
to
43d67ae
Compare
Master branch: 57385ae |
43d67ae
to
d6bf644
Compare
Master branch: 1000298 |
d6bf644
to
8a3d6e1
Compare
Master branch: 59f2a29 |
8a3d6e1
to
8a786f2
Compare
Master branch: e89ef63 |
8a786f2
to
d376855
Compare
The llvm patches ([1], [2]) added support to attach btf_decl_tag attributes to typedef declarations. This patch added support in kernel. [1] https://reviews.llvm.org/D110127 [2] https://reviews.llvm.org/D112259 Signed-off-by: Yonghong Song <yhs@fb.com>
Test good and bad variants of typedef BTF_KIND_DECL_TAG encoding. Signed-off-by: Yonghong Song <yhs@fb.com>
Add unit tests for deduplication of BTF_KIND_DECL_TAG to typedef types. Also changed a few comments from "tag" to "decl_tag" to match BTF_KIND_DECL_TAG enum value name. Signed-off-by: Yonghong Song <yhs@fb.com>
Change value type in progs/tag.c to a typedef with a btf_decl_tag. With `bpftool btf dump file tag.o`, we have ... [14] TYPEDEF 'value_t' type_id=17 [15] DECL_TAG 'tag1' type_id=14 component_idx=-1 [16] DECL_TAG 'tag2' type_id=14 component_idx=-1 [17] STRUCT '(anon)' size=8 vlen=2 'a' type_id=2 bits_offset=0 'b' type_id=2 bits_offset=32 ... The btf_tag selftest also succeeded: $ ./test_progs -t tag #21 btf_tag:OK Summary: 1/0 PASSED, 0 SKIPPED, 0 FAILED Signed-off-by: Yonghong Song <yhs@fb.com>
Add BTF_KIND_DECL_TAG typedef support in btf.rst. Signed-off-by: Yonghong Song <yhs@fb.com>
Master branch: a33f607 |
d376855
to
dbed823
Compare
At least one diff in series https://patchwork.kernel.org/project/netdevbpf/list/?series=568137 irrelevant now. Closing PR. |
Pull request for series with
subject: bpf: add support for BTF_KIND_DECL_TAG typedef
version: 1
url: https://patchwork.kernel.org/project/netdevbpf/list/?series=568137