summaryrefslogtreecommitdiffstats
path: root/tools/include
diff options
context:
space:
mode:
authorLorenzo Bianconi <lorenzo@kernel.org>2022-01-21 11:09:52 +0100
committerAlexei Starovoitov <ast@kernel.org>2022-01-21 14:14:01 -0800
commitc2f2cdbeffda7b153c19e0f3d73149c41026c0db (patch)
treeb9805b2b601ec574d39f8a553e892e78a1ac034c /tools/include
parentc41ced023a9892572bd0ec8c3af0bd99faefd31f (diff)
downloadlinux-stable-c2f2cdbeffda7b153c19e0f3d73149c41026c0db.tar.gz
linux-stable-c2f2cdbeffda7b153c19e0f3d73149c41026c0db.tar.bz2
linux-stable-c2f2cdbeffda7b153c19e0f3d73149c41026c0db.zip
bpf: introduce BPF_F_XDP_HAS_FRAGS flag in prog_flags loading the ebpf program
Introduce BPF_F_XDP_HAS_FRAGS and the related field in bpf_prog_aux in order to notify the driver the loaded program support xdp frags. Acked-by: Toke Hoiland-Jorgensen <toke@redhat.com> Acked-by: John Fastabend <john.fastabend@gmail.com> Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org> Link: https://lore.kernel.org/r/db2e8075b7032a356003f407d1b0deb99adaa0ed.1642758637.git.lorenzo@kernel.org Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'tools/include')
-rw-r--r--tools/include/uapi/linux/bpf.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/tools/include/uapi/linux/bpf.h b/tools/include/uapi/linux/bpf.h
index fe2272defcd9..945649c67e03 100644
--- a/tools/include/uapi/linux/bpf.h
+++ b/tools/include/uapi/linux/bpf.h
@@ -1113,6 +1113,11 @@ enum bpf_link_type {
*/
#define BPF_F_SLEEPABLE (1U << 4)
+/* If BPF_F_XDP_HAS_FRAGS is used in BPF_PROG_LOAD command, the loaded program
+ * fully support xdp frags.
+ */
+#define BPF_F_XDP_HAS_FRAGS (1U << 5)
+
/* When BPF ldimm64's insn[0].src_reg != 0 then this can have
* the following extensions:
*