summaryrefslogtreecommitdiffstats
path: root/Documentation/bpf
diff options
context:
space:
mode:
authorDave Thaler <dthaler1968@googlemail.com>2024-01-08 13:42:31 -0800
committerAlexei Starovoitov <ast@kernel.org>2024-01-23 14:40:22 -0800
commit81777efbf59305fa145bede97dd4abdc35540578 (patch)
tree957f589dbaf8ec53fa54a7bf496de7fa03e37bae /Documentation/bpf
parent15b8b0be985592fd19ee4e661d13d291877b09c7 (diff)
downloadlinux-81777efbf59305fa145bede97dd4abdc35540578.tar.gz
linux-81777efbf59305fa145bede97dd4abdc35540578.tar.bz2
linux-81777efbf59305fa145bede97dd4abdc35540578.zip
Introduce concept of conformance groups
The discussion of what the actual conformance groups should be is still in progress, so this is just part 1 which only uses "legacy" for deprecated instructions and "basic" for everything else. Subsequent patches will add more groups as discussion continues. Signed-off-by: Dave Thaler <dthaler1968@gmail.com> Acked-by: David Vernet <void@manifault.com> Link: https://lore.kernel.org/r/20240108214231.5280-1-dthaler1968@gmail.com Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'Documentation/bpf')
-rw-r--r--Documentation/bpf/standardization/instruction-set.rst26
1 files changed, 25 insertions, 1 deletions
diff --git a/Documentation/bpf/standardization/instruction-set.rst b/Documentation/bpf/standardization/instruction-set.rst
index 245b6defc298..eb0f234a8001 100644
--- a/Documentation/bpf/standardization/instruction-set.rst
+++ b/Documentation/bpf/standardization/instruction-set.rst
@@ -97,6 +97,28 @@ Definitions
A: 10000110
B: 11111111 10000110
+Conformance groups
+------------------
+
+An implementation does not need to support all instructions specified in this
+document (e.g., deprecated instructions). Instead, a number of conformance
+groups are specified. An implementation must support the "basic" conformance
+group and may support additional conformance groups, where supporting a
+conformance group means it must support all instructions in that conformance
+group.
+
+The use of named conformance groups enables interoperability between a runtime
+that executes instructions, and tools as such compilers that generate
+instructions for the runtime. Thus, capability discovery in terms of
+conformance groups might be done manually by users or automatically by tools.
+
+Each conformance group has a short ASCII label (e.g., "basic") that
+corresponds to a set of instructions that are mandatory. That is, each
+instruction has one or more conformance groups of which it is a member.
+
+The "basic" conformance group includes all instructions defined in this
+specification unless otherwise noted.
+
Instruction encoding
====================
@@ -610,4 +632,6 @@ Legacy BPF Packet access instructions
BPF previously introduced special instructions for access to packet data that were
carried over from classic BPF. However, these instructions are
-deprecated and should no longer be used.
+deprecated and should no longer be used. All legacy packet access
+instructions belong to the "legacy" conformance group instead of the "basic"
+conformance group.