summaryrefslogtreecommitdiff
path: root/include/net/tc_act
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2015-01-19 00:35:14 +0300
committerDavid S. Miller <davem@davemloft.net>2015-01-20 00:02:06 +0300
commit22a5dc0e5e3e8fef804230cd73ed7b0afd4c7bae (patch)
tree0f25f92070e4208f89b8cbc59eda605347dfc95b /include/net/tc_act
parentcbcd1fa72c7cc4ac5b8c8554731fdb06ac7ddaa8 (diff)
downloadlinux-22a5dc0e5e3e8fef804230cd73ed7b0afd4c7bae.tar.xz
net: sched: Introduce connmark action
This tc action allows you to retrieve the connection tracking mark This action has been used heavily by openwrt for a few years now. There are known limitations currently: doesn't work for initial packets, since we only query the ct table. Fine given use case is for returning packets no implicit defrag. frags should be rare so fix later.. won't work for more complex tasks, e.g. lookup of other extensions since we have no means to store results we still have a 2nd lookup later on via normal conntrack path. This shouldn't break anything though since skb->nfct isn't altered. V2: remove unnecessary braces (Jiri) change the action identifier to 14 (Jiri) Fix some stylistic issues caught by checkpatch V3: Move module params to bottom (Cong) Get rid of tcf_hashinfo_init and friends and conform to newer API (Cong) Acked-by: Jiri Pirko <jiri@resnulli.us> Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: Jamal Hadi Salim <jhs@mojatatu.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/tc_act')
-rw-r--r--include/net/tc_act/tc_connmark.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/include/net/tc_act/tc_connmark.h b/include/net/tc_act/tc_connmark.h
new file mode 100644
index 000000000000..5c1104c2e24f
--- /dev/null
+++ b/include/net/tc_act/tc_connmark.h
@@ -0,0 +1,14 @@
+#ifndef __NET_TC_CONNMARK_H
+#define __NET_TC_CONNMARK_H
+
+#include <net/act_api.h>
+
+struct tcf_connmark_info {
+ struct tcf_common common;
+ u16 zone;
+};
+
+#define to_connmark(a) \
+ container_of(a->priv, struct tcf_connmark_info, common)
+
+#endif /* __NET_TC_CONNMARK_H */