Skip to contentSkip to conversation

tc: add cls_bpf frontend

PATCH Applied Daniel Borkmann 2 participants 2 messages Oct 28, 2013 – Oct 30, 2013

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tc: add cls_bpf frontend

This is the iproute2 part of the kernel patch "net: sched:
add BPF-based traffic classifier".

[Will re-submit later again for iproute2 when window for
-next submissions opens.]

---
 include/linux/pkt_cls.h |  14 +++
 tc/Makefile             |   1 +
 tc/f_bpf.c              | 288 ++++++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 303 insertions(+)
 create mode 100644 tc/f_bpf.c
include/linux/pkt_cls.h +14 -0
index 082eafa..25731df 100644
@@ -388,6 +388,20 @@ enum {
 
 #define TCA_CGROUP_MAX (__TCA_CGROUP_MAX - 1)
 
+/* BPF classifier */
+
+enum {
+	TCA_BPF_UNSPEC,
+	TCA_BPF_ACT,
+	TCA_BPF_POLICE,
+	TCA_BPF_CLASSID,
+	TCA_BPF_OPS_LEN,
+	TCA_BPF_OPS,
+	__TCA_BPF_MAX,
+};
+
+#define TCA_BPF_MAX (__TCA_BPF_MAX - 1)
+
 /* Extended Matches */
 
 struct tcf_ematch_tree_hdr {
tc/Makefile +1 -0
index f54a955..84215c0 100644
@@ -22,6 +22,7 @@ TCMODULES += f_u32.o
 TCMODULES += f_route.o
 TCMODULES += f_fw.o
 TCMODULES += f_basic.o
+TCMODULES += f_bpf.o
 TCMODULES += f_flow.o
 TCMODULES += f_cgroup.o
 TCMODULES += q_dsmark.o
tc/f_bpf.c new file +288 -0

288 lines not on this page · raw message

Signature · 1 line
1.8.3.1
#1 lore raw
Quoted 3 lines · On Mon, 28 Oct 2013 12:35:33 +0100 Daniel Borkmann <[email protected]> wrote:

This is the iproute2 part of the kernel patch "net: sched:
add BPF-based traffic classifier".

Applied to net-next-3.11 branch