summaryrefslogtreecommitdiffstats
path: root/tools/lib
diff options
context:
space:
mode:
authorDaniel Müller <deso@posteo.net>2022-06-28 18:01:18 +0200
committerAndrii Nakryiko <andrii@kernel.org>2022-07-06 05:24:12 +0200
commit3c660a5d86f4c01cf641bfea004a49f5860a5bed (patch)
treecd5bd3ed487f7efc30b30213e92dfbe635f72df0 /tools/lib
parentbpf, samples: Remove AF_XDP samples (diff)
downloadlinux-3c660a5d86f4c01cf641bfea004a49f5860a5bed.tar.xz
linux-3c660a5d86f4c01cf641bfea004a49f5860a5bed.zip
bpf: Introduce TYPE_MATCH related constants/macros
In order to provide type match support we require a new type of relocation which, in turn, requires toolchain support. Recent LLVM/Clang versions support a new value for the last argument to the __builtin_preserve_type_info builtin, for example. With this change we introduce the necessary constants into relevant header files, mirroring what the compiler may support. Signed-off-by: Daniel Müller <deso@posteo.net> Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/bpf/20220628160127.607834-2-deso@posteo.net
Diffstat (limited to 'tools/lib')
-rw-r--r--tools/lib/bpf/bpf_core_read.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/lib/bpf/bpf_core_read.h b/tools/lib/bpf/bpf_core_read.h
index fd48b1ff59ca..2308f4990e96 100644
--- a/tools/lib/bpf/bpf_core_read.h
+++ b/tools/lib/bpf/bpf_core_read.h
@@ -29,6 +29,7 @@ enum bpf_type_id_kind {
enum bpf_type_info_kind {
BPF_TYPE_EXISTS = 0, /* type existence in target kernel */
BPF_TYPE_SIZE = 1, /* type size in target kernel */
+ BPF_TYPE_MATCHES = 2, /* type match in target kernel */
};
/* second argument to __builtin_preserve_enum_value() built-in */