aboutsummaryrefslogtreecommitdiffstats
path: root/include/uapi/linux/pkt_cls.h
diff options
context:
space:
mode:
authorCong Wang <xiyou.wangcong@gmail.com>2019-01-17 12:44:25 -0800
committerDavid S. Miller <davem@davemloft.net>2019-01-18 14:13:50 -0800
commitf88c19aab5f34835f1ba467c5b508ec4f782f07f (patch)
tree1190848eca86af1f5f29c13fd4eae215b063b29d /include/uapi/linux/pkt_cls.h
parentMerge branch 'phy-improve-stopping-PHY' (diff)
downloadlinux-dev-f88c19aab5f34835f1ba467c5b508ec4f782f07f.tar.xz
linux-dev-f88c19aab5f34835f1ba467c5b508ec4f782f07f.zip
net_sched: add hit counter for matchall
Although matchall always matches packets, however, it still relies on a protocol match first. So it is still useful to have such a counter for matchall. Of course, unlike u32, every time we hit a matchall filter, it is always a success, so we don't have to distinguish them. Sample output: filter protocol 802.1Q pref 100 matchall chain 0 filter protocol 802.1Q pref 100 matchall chain 0 handle 0x1 not_in_hw (rule hit 10) action order 1: vlan pop continue index 1 ref 1 bind 1 installed 40 sec used 1 sec Action statistics: Sent 836 bytes 10 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0 Reported-by: Martin Olsson <martin.olsson+netdev@sentorsecurity.com> Cc: Jamal Hadi Salim <jhs@mojatatu.com> Cc: Jiri Pirko <jiri@resnulli.us> Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/uapi/linux/pkt_cls.h')
-rw-r--r--include/uapi/linux/pkt_cls.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/uapi/linux/pkt_cls.h b/include/uapi/linux/pkt_cls.h
index 95d0db2a8350..32a3416b51c3 100644
--- a/include/uapi/linux/pkt_cls.h
+++ b/include/uapi/linux/pkt_cls.h
@@ -527,11 +527,17 @@ enum {
/* Match-all classifier */
+struct tc_matchall_pcnt {
+ __u64 rhit;
+};
+
enum {
TCA_MATCHALL_UNSPEC,
TCA_MATCHALL_CLASSID,
TCA_MATCHALL_ACT,
TCA_MATCHALL_FLAGS,
+ TCA_MATCHALL_PCNT,
+ TCA_MATCHALL_PAD,
__TCA_MATCHALL_MAX,
};