2 * net/sched/cls_api.c Packet classifier API.
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation; either version
7 * 2 of the License, or (at your option) any later version.
9 * Authors: Alexey Kuznetsov, <kuznet@ms2.inr.ac.ru>
13 * Eduardo J. Blanco <ejbs@netlabs.com.uy> :990222: kmod support
17 #include <linux/module.h>
18 #include <linux/types.h>
19 #include <linux/kernel.h>
20 #include <linux/string.h>
21 #include <linux/errno.h>
22 #include <linux/err.h>
23 #include <linux/skbuff.h>
24 #include <linux/init.h>
25 #include <linux/kmod.h>
26 #include <linux/err.h>
27 #include <linux/slab.h>
28 #include <net/net_namespace.h>
30 #include <net/netlink.h>
31 #include <net/pkt_sched.h>
32 #include <net/pkt_cls.h>
34 /* The list of all installed classifier types */
35 static LIST_HEAD(tcf_proto_base);
37 /* Protects list of registered TC modules. It is pure SMP lock. */
38 static DEFINE_RWLOCK(cls_mod_lock);
40 /* Find classifier type by string name */
42 static const struct tcf_proto_ops *tcf_proto_lookup_ops(const char *kind)
44 const struct tcf_proto_ops *t, *res = NULL;
47 read_lock(&cls_mod_lock);
48 list_for_each_entry(t, &tcf_proto_base, head) {
49 if (strcmp(kind, t->kind) == 0) {
50 if (try_module_get(t->owner))
55 read_unlock(&cls_mod_lock);
60 /* Register(unregister) new classifier type */
62 int register_tcf_proto_ops(struct tcf_proto_ops *ops)
64 struct tcf_proto_ops *t;
67 write_lock(&cls_mod_lock);
68 list_for_each_entry(t, &tcf_proto_base, head)
69 if (!strcmp(ops->kind, t->kind))
72 list_add_tail(&ops->head, &tcf_proto_base);
75 write_unlock(&cls_mod_lock);
78 EXPORT_SYMBOL(register_tcf_proto_ops);
80 int unregister_tcf_proto_ops(struct tcf_proto_ops *ops)
82 struct tcf_proto_ops *t;
85 /* Wait for outstanding call_rcu()s, if any, from a
86 * tcf_proto_ops's destroy() handler.
90 write_lock(&cls_mod_lock);
91 list_for_each_entry(t, &tcf_proto_base, head) {
98 write_unlock(&cls_mod_lock);
101 EXPORT_SYMBOL(unregister_tcf_proto_ops);
103 static int tfilter_notify(struct net *net, struct sk_buff *oskb,
104 struct nlmsghdr *n, struct tcf_proto *tp,
105 unsigned long fh, int event, bool unicast);
107 static void tfilter_notify_chain(struct net *net, struct sk_buff *oskb,
109 struct tcf_chain *chain, int event)
111 struct tcf_proto *tp;
113 for (tp = rtnl_dereference(chain->filter_chain);
114 tp; tp = rtnl_dereference(tp->next))
115 tfilter_notify(net, oskb, n, tp, 0, event, false);
118 /* Select new prio value from the range, managed by kernel. */
120 static inline u32 tcf_auto_prio(struct tcf_proto *tp)
122 u32 first = TC_H_MAKE(0xC0000000U, 0U);
125 first = tp->prio - 1;
127 return TC_H_MAJ(first);
130 static struct tcf_proto *tcf_proto_create(const char *kind, u32 protocol,
131 u32 prio, u32 parent, struct Qdisc *q,
132 struct tcf_chain *chain)
134 struct tcf_proto *tp;
137 tp = kzalloc(sizeof(*tp), GFP_KERNEL);
139 return ERR_PTR(-ENOBUFS);
142 tp->ops = tcf_proto_lookup_ops(kind);
144 #ifdef CONFIG_MODULES
146 request_module("cls_%s", kind);
148 tp->ops = tcf_proto_lookup_ops(kind);
149 /* We dropped the RTNL semaphore in order to perform
150 * the module load. So, even if we succeeded in loading
151 * the module we have to replay the request. We indicate
152 * this using -EAGAIN.
155 module_put(tp->ops->owner);
163 tp->classify = tp->ops->classify;
164 tp->protocol = protocol;
166 tp->classid = parent;
170 err = tp->ops->init(tp);
172 module_put(tp->ops->owner);
182 static void tcf_proto_destroy(struct tcf_proto *tp)
184 tp->ops->destroy(tp);
185 module_put(tp->ops->owner);
189 static struct tcf_chain *tcf_chain_create(struct tcf_block *block,
192 struct tcf_chain *chain;
194 chain = kzalloc(sizeof(*chain), GFP_KERNEL);
197 list_add_tail(&chain->list, &block->chain_list);
198 chain->block = block;
199 chain->index = chain_index;
204 static void tcf_chain_flush(struct tcf_chain *chain)
206 struct tcf_proto *tp;
208 if (*chain->p_filter_chain)
209 RCU_INIT_POINTER(*chain->p_filter_chain, NULL);
210 while ((tp = rtnl_dereference(chain->filter_chain)) != NULL) {
211 RCU_INIT_POINTER(chain->filter_chain, tp->next);
212 tcf_proto_destroy(tp);
216 static void tcf_chain_destroy(struct tcf_chain *chain)
218 list_del(&chain->list);
219 tcf_chain_flush(chain);
223 struct tcf_chain *tcf_chain_get(struct tcf_block *block, u32 chain_index)
225 struct tcf_chain *chain;
227 list_for_each_entry(chain, &block->chain_list, list) {
228 if (chain->index == chain_index) {
233 return tcf_chain_create(block, chain_index);
235 EXPORT_SYMBOL(tcf_chain_get);
237 void tcf_chain_put(struct tcf_chain *chain)
239 /* Destroy unused chain, with exception of chain 0, which is the
240 * default one and has to be always present.
242 if (--chain->refcnt == 0 && !chain->filter_chain && chain->index != 0)
243 tcf_chain_destroy(chain);
245 EXPORT_SYMBOL(tcf_chain_put);
248 tcf_chain_filter_chain_ptr_set(struct tcf_chain *chain,
249 struct tcf_proto __rcu **p_filter_chain)
251 chain->p_filter_chain = p_filter_chain;
254 int tcf_block_get(struct tcf_block **p_block,
255 struct tcf_proto __rcu **p_filter_chain)
257 struct tcf_block *block = kzalloc(sizeof(*block), GFP_KERNEL);
258 struct tcf_chain *chain;
263 INIT_LIST_HEAD(&block->chain_list);
264 /* Create chain 0 by default, it has to be always present. */
265 chain = tcf_chain_create(block, 0);
268 goto err_chain_create;
270 tcf_chain_filter_chain_ptr_set(chain, p_filter_chain);
278 EXPORT_SYMBOL(tcf_block_get);
280 void tcf_block_put(struct tcf_block *block)
282 struct tcf_chain *chain, *tmp;
287 list_for_each_entry_safe(chain, tmp, &block->chain_list, list)
288 tcf_chain_destroy(chain);
291 EXPORT_SYMBOL(tcf_block_put);
293 /* Main classifier routine: scans classifier chain attached
294 * to this qdisc, (optionally) tests for protocol and asks
295 * specific classifiers.
297 int tcf_classify(struct sk_buff *skb, const struct tcf_proto *tp,
298 struct tcf_result *res, bool compat_mode)
300 __be16 protocol = tc_skb_protocol(skb);
301 #ifdef CONFIG_NET_CLS_ACT
302 const int max_reclassify_loop = 4;
303 const struct tcf_proto *orig_tp = tp;
304 const struct tcf_proto *first_tp;
309 for (; tp; tp = rcu_dereference_bh(tp->next)) {
312 if (tp->protocol != protocol &&
313 tp->protocol != htons(ETH_P_ALL))
316 err = tp->classify(skb, tp, res);
317 #ifdef CONFIG_NET_CLS_ACT
318 if (unlikely(err == TC_ACT_RECLASSIFY && !compat_mode)) {
321 } else if (unlikely(TC_ACT_EXT_CMP(err, TC_ACT_GOTO_CHAIN))) {
322 first_tp = res->goto_tp;
330 return TC_ACT_UNSPEC; /* signal: continue lookup */
331 #ifdef CONFIG_NET_CLS_ACT
333 if (unlikely(limit++ >= max_reclassify_loop)) {
334 net_notice_ratelimited("%s: reclassify loop, rule prio %u, protocol %02x\n",
335 tp->q->ops->id, tp->prio & 0xffff,
336 ntohs(tp->protocol));
341 protocol = tc_skb_protocol(skb);
345 EXPORT_SYMBOL(tcf_classify);
347 struct tcf_chain_info {
348 struct tcf_proto __rcu **pprev;
349 struct tcf_proto __rcu *next;
352 static struct tcf_proto *tcf_chain_tp_prev(struct tcf_chain_info *chain_info)
354 return rtnl_dereference(*chain_info->pprev);
357 static void tcf_chain_tp_insert(struct tcf_chain *chain,
358 struct tcf_chain_info *chain_info,
359 struct tcf_proto *tp)
361 if (chain->p_filter_chain &&
362 *chain_info->pprev == chain->filter_chain)
363 rcu_assign_pointer(*chain->p_filter_chain, tp);
364 RCU_INIT_POINTER(tp->next, tcf_chain_tp_prev(chain_info));
365 rcu_assign_pointer(*chain_info->pprev, tp);
368 static void tcf_chain_tp_remove(struct tcf_chain *chain,
369 struct tcf_chain_info *chain_info,
370 struct tcf_proto *tp)
372 struct tcf_proto *next = rtnl_dereference(chain_info->next);
374 if (chain->p_filter_chain && tp == chain->filter_chain)
375 RCU_INIT_POINTER(*chain->p_filter_chain, next);
376 RCU_INIT_POINTER(*chain_info->pprev, next);
379 static struct tcf_proto *tcf_chain_tp_find(struct tcf_chain *chain,
380 struct tcf_chain_info *chain_info,
381 u32 protocol, u32 prio,
384 struct tcf_proto **pprev;
385 struct tcf_proto *tp;
387 /* Check the chain for existence of proto-tcf with this priority */
388 for (pprev = &chain->filter_chain;
389 (tp = rtnl_dereference(*pprev)); pprev = &tp->next) {
390 if (tp->prio >= prio) {
391 if (tp->prio == prio) {
393 (tp->protocol != protocol && protocol))
394 return ERR_PTR(-EINVAL);
401 chain_info->pprev = pprev;
402 chain_info->next = tp ? tp->next : NULL;
406 /* Add/change/delete/get a filter node */
408 static int tc_ctl_tfilter(struct sk_buff *skb, struct nlmsghdr *n,
409 struct netlink_ext_ack *extack)
411 struct net *net = sock_net(skb->sk);
412 struct nlattr *tca[TCA_MAX + 1];
419 struct net_device *dev;
421 struct tcf_chain_info chain_info;
422 struct tcf_chain *chain = NULL;
423 struct tcf_block *block;
424 struct tcf_proto *tp;
425 const struct Qdisc_class_ops *cops;
431 if ((n->nlmsg_type != RTM_GETTFILTER) &&
432 !netlink_ns_capable(skb, net->user_ns, CAP_NET_ADMIN))
438 err = nlmsg_parse(n, sizeof(*t), tca, TCA_MAX, NULL, extack);
443 protocol = TC_H_MIN(t->tcm_info);
444 prio = TC_H_MAJ(t->tcm_info);
445 prio_allocate = false;
446 parent = t->tcm_parent;
450 switch (n->nlmsg_type) {
452 if (protocol || t->tcm_handle || tca[TCA_KIND])
456 /* If no priority is provided by the user,
459 if (n->nlmsg_flags & NLM_F_CREATE) {
460 prio = TC_H_MAKE(0x80000000U, 0U);
461 prio_allocate = true;
470 /* Find head of filter chain. */
473 dev = __dev_get_by_index(net, t->tcm_ifindex);
482 q = qdisc_lookup(dev, TC_H_MAJ(t->tcm_parent));
487 /* Is it classful? */
488 cops = q->ops->cl_ops;
492 if (!cops->tcf_block)
495 /* Do we search for filter, attached to class? */
496 if (TC_H_MIN(parent)) {
497 cl = cops->get(q, parent);
502 /* And the last stroke */
503 block = cops->tcf_block(q, cl);
509 chain_index = tca[TCA_CHAIN] ? nla_get_u32(tca[TCA_CHAIN]) : 0;
510 if (chain_index > TC_ACT_EXT_VAL_MASK) {
514 chain = tcf_chain_get(block, chain_index);
520 if (n->nlmsg_type == RTM_DELTFILTER && prio == 0) {
521 tfilter_notify_chain(net, skb, n, chain, RTM_DELTFILTER);
522 tcf_chain_flush(chain);
527 tp = tcf_chain_tp_find(chain, &chain_info, protocol,
528 prio, prio_allocate);
535 /* Proto-tcf does not exist, create new one */
537 if (tca[TCA_KIND] == NULL || !protocol) {
542 if (n->nlmsg_type != RTM_NEWTFILTER ||
543 !(n->nlmsg_flags & NLM_F_CREATE)) {
549 prio = tcf_auto_prio(tcf_chain_tp_prev(&chain_info));
551 tp = tcf_proto_create(nla_data(tca[TCA_KIND]),
552 protocol, prio, parent, q, chain);
558 } else if (tca[TCA_KIND] && nla_strcmp(tca[TCA_KIND], tp->ops->kind)) {
563 fh = tp->ops->get(tp, t->tcm_handle);
566 if (n->nlmsg_type == RTM_DELTFILTER && t->tcm_handle == 0) {
567 tcf_chain_tp_remove(chain, &chain_info, tp);
568 tfilter_notify(net, skb, n, tp, fh,
569 RTM_DELTFILTER, false);
570 tcf_proto_destroy(tp);
575 if (n->nlmsg_type != RTM_NEWTFILTER ||
576 !(n->nlmsg_flags & NLM_F_CREATE)) {
583 switch (n->nlmsg_type) {
585 if (n->nlmsg_flags & NLM_F_EXCL) {
587 tcf_proto_destroy(tp);
593 err = tp->ops->delete(tp, fh, &last);
596 tfilter_notify(net, skb, n, tp, t->tcm_handle,
597 RTM_DELTFILTER, false);
599 tcf_chain_tp_remove(chain, &chain_info, tp);
600 tcf_proto_destroy(tp);
604 err = tfilter_notify(net, skb, n, tp, fh,
605 RTM_NEWTFILTER, true);
613 err = tp->ops->change(net, skb, tp, cl, t->tcm_handle, tca, &fh,
614 n->nlmsg_flags & NLM_F_CREATE ? TCA_ACT_NOREPLACE : TCA_ACT_REPLACE);
617 tcf_chain_tp_insert(chain, &chain_info, tp);
618 tfilter_notify(net, skb, n, tp, fh, RTM_NEWTFILTER, false);
621 tcf_proto_destroy(tp);
626 tcf_chain_put(chain);
630 /* Replay the request. */
635 static int tcf_fill_node(struct net *net, struct sk_buff *skb,
636 struct tcf_proto *tp, unsigned long fh, u32 portid,
637 u32 seq, u16 flags, int event)
640 struct nlmsghdr *nlh;
641 unsigned char *b = skb_tail_pointer(skb);
643 nlh = nlmsg_put(skb, portid, seq, event, sizeof(*tcm), flags);
646 tcm = nlmsg_data(nlh);
647 tcm->tcm_family = AF_UNSPEC;
650 tcm->tcm_ifindex = qdisc_dev(tp->q)->ifindex;
651 tcm->tcm_parent = tp->classid;
652 tcm->tcm_info = TC_H_MAKE(tp->prio, tp->protocol);
653 if (nla_put_string(skb, TCA_KIND, tp->ops->kind))
654 goto nla_put_failure;
655 if (nla_put_u32(skb, TCA_CHAIN, tp->chain->index))
656 goto nla_put_failure;
657 tcm->tcm_handle = fh;
658 if (RTM_DELTFILTER != event) {
660 if (tp->ops->dump && tp->ops->dump(net, tp, fh, skb, tcm) < 0)
661 goto nla_put_failure;
663 nlh->nlmsg_len = skb_tail_pointer(skb) - b;
672 static int tfilter_notify(struct net *net, struct sk_buff *oskb,
673 struct nlmsghdr *n, struct tcf_proto *tp,
674 unsigned long fh, int event, bool unicast)
677 u32 portid = oskb ? NETLINK_CB(oskb).portid : 0;
679 skb = alloc_skb(NLMSG_GOODSIZE, GFP_KERNEL);
683 if (tcf_fill_node(net, skb, tp, fh, portid, n->nlmsg_seq,
684 n->nlmsg_flags, event) <= 0) {
690 return netlink_unicast(net->rtnl, skb, portid, MSG_DONTWAIT);
692 return rtnetlink_send(skb, net, portid, RTNLGRP_TC,
693 n->nlmsg_flags & NLM_F_ECHO);
696 struct tcf_dump_args {
699 struct netlink_callback *cb;
702 static int tcf_node_dump(struct tcf_proto *tp, unsigned long n,
703 struct tcf_walker *arg)
705 struct tcf_dump_args *a = (void *)arg;
706 struct net *net = sock_net(a->skb->sk);
708 return tcf_fill_node(net, a->skb, tp, n, NETLINK_CB(a->cb->skb).portid,
709 a->cb->nlh->nlmsg_seq, NLM_F_MULTI,
713 static bool tcf_chain_dump(struct tcf_chain *chain, struct sk_buff *skb,
714 struct netlink_callback *cb,
715 long index_start, long *p_index)
717 struct net *net = sock_net(skb->sk);
718 struct tcmsg *tcm = nlmsg_data(cb->nlh);
719 struct tcf_dump_args arg;
720 struct tcf_proto *tp;
722 for (tp = rtnl_dereference(chain->filter_chain);
723 tp; tp = rtnl_dereference(tp->next), (*p_index)++) {
724 if (*p_index < index_start)
726 if (TC_H_MAJ(tcm->tcm_info) &&
727 TC_H_MAJ(tcm->tcm_info) != tp->prio)
729 if (TC_H_MIN(tcm->tcm_info) &&
730 TC_H_MIN(tcm->tcm_info) != tp->protocol)
732 if (*p_index > index_start)
733 memset(&cb->args[1], 0,
734 sizeof(cb->args) - sizeof(cb->args[0]));
735 if (cb->args[1] == 0) {
736 if (tcf_fill_node(net, skb, tp, 0,
737 NETLINK_CB(cb->skb).portid,
738 cb->nlh->nlmsg_seq, NLM_F_MULTI,
739 RTM_NEWTFILTER) <= 0)
746 arg.w.fn = tcf_node_dump;
750 arg.w.skip = cb->args[1] - 1;
752 tp->ops->walk(tp, &arg.w);
753 cb->args[1] = arg.w.count + 1;
760 /* called with RTNL */
761 static int tc_dump_tfilter(struct sk_buff *skb, struct netlink_callback *cb)
763 struct net *net = sock_net(skb->sk);
764 struct nlattr *tca[TCA_MAX + 1];
765 struct net_device *dev;
767 struct tcf_block *block;
768 struct tcf_chain *chain;
769 struct tcmsg *tcm = nlmsg_data(cb->nlh);
770 unsigned long cl = 0;
771 const struct Qdisc_class_ops *cops;
776 if (nlmsg_len(cb->nlh) < sizeof(*tcm))
779 err = nlmsg_parse(cb->nlh, sizeof(*tcm), tca, TCA_MAX, NULL, NULL);
783 dev = __dev_get_by_index(net, tcm->tcm_ifindex);
787 if (!tcm->tcm_parent)
790 q = qdisc_lookup(dev, TC_H_MAJ(tcm->tcm_parent));
793 cops = q->ops->cl_ops;
796 if (!cops->tcf_block)
798 if (TC_H_MIN(tcm->tcm_parent)) {
799 cl = cops->get(q, tcm->tcm_parent);
803 block = cops->tcf_block(q, cl);
807 index_start = cb->args[0];
810 list_for_each_entry(chain, &block->chain_list, list) {
811 if (tca[TCA_CHAIN] &&
812 nla_get_u32(tca[TCA_CHAIN]) != chain->index)
814 if (!tcf_chain_dump(chain, skb, cb, index_start, &index))
827 void tcf_exts_destroy(struct tcf_exts *exts)
829 #ifdef CONFIG_NET_CLS_ACT
832 tcf_exts_to_list(exts, &actions);
833 tcf_action_destroy(&actions, TCA_ACT_UNBIND);
834 kfree(exts->actions);
835 exts->nr_actions = 0;
838 EXPORT_SYMBOL(tcf_exts_destroy);
840 int tcf_exts_validate(struct net *net, struct tcf_proto *tp, struct nlattr **tb,
841 struct nlattr *rate_tlv, struct tcf_exts *exts, bool ovr)
843 #ifdef CONFIG_NET_CLS_ACT
845 struct tc_action *act;
847 if (exts->police && tb[exts->police]) {
848 act = tcf_action_init_1(net, tp, tb[exts->police],
849 rate_tlv, "police", ovr,
854 act->type = exts->type = TCA_OLD_COMPAT;
855 exts->actions[0] = act;
856 exts->nr_actions = 1;
857 } else if (exts->action && tb[exts->action]) {
861 err = tcf_action_init(net, tp, tb[exts->action],
862 rate_tlv, NULL, ovr, TCA_ACT_BIND,
866 list_for_each_entry(act, &actions, list)
867 exts->actions[i++] = act;
868 exts->nr_actions = i;
872 if ((exts->action && tb[exts->action]) ||
873 (exts->police && tb[exts->police]))
879 EXPORT_SYMBOL(tcf_exts_validate);
881 void tcf_exts_change(struct tcf_proto *tp, struct tcf_exts *dst,
882 struct tcf_exts *src)
884 #ifdef CONFIG_NET_CLS_ACT
885 struct tcf_exts old = *dst;
888 dst->nr_actions = src->nr_actions;
889 dst->actions = src->actions;
890 dst->type = src->type;
893 tcf_exts_destroy(&old);
896 EXPORT_SYMBOL(tcf_exts_change);
898 #ifdef CONFIG_NET_CLS_ACT
899 static struct tc_action *tcf_exts_first_act(struct tcf_exts *exts)
901 if (exts->nr_actions == 0)
904 return exts->actions[0];
908 int tcf_exts_dump(struct sk_buff *skb, struct tcf_exts *exts)
910 #ifdef CONFIG_NET_CLS_ACT
913 if (exts->action && exts->nr_actions) {
915 * again for backward compatible mode - we want
916 * to work with both old and new modes of entering
917 * tc data even if iproute2 was newer - jhs
919 if (exts->type != TCA_OLD_COMPAT) {
922 nest = nla_nest_start(skb, exts->action);
924 goto nla_put_failure;
926 tcf_exts_to_list(exts, &actions);
927 if (tcf_action_dump(skb, &actions, 0, 0) < 0)
928 goto nla_put_failure;
929 nla_nest_end(skb, nest);
930 } else if (exts->police) {
931 struct tc_action *act = tcf_exts_first_act(exts);
932 nest = nla_nest_start(skb, exts->police);
933 if (nest == NULL || !act)
934 goto nla_put_failure;
935 if (tcf_action_dump_old(skb, act, 0, 0) < 0)
936 goto nla_put_failure;
937 nla_nest_end(skb, nest);
943 nla_nest_cancel(skb, nest);
949 EXPORT_SYMBOL(tcf_exts_dump);
952 int tcf_exts_dump_stats(struct sk_buff *skb, struct tcf_exts *exts)
954 #ifdef CONFIG_NET_CLS_ACT
955 struct tc_action *a = tcf_exts_first_act(exts);
956 if (a != NULL && tcf_action_copy_stats(skb, a, 1) < 0)
961 EXPORT_SYMBOL(tcf_exts_dump_stats);
963 int tcf_exts_get_dev(struct net_device *dev, struct tcf_exts *exts,
964 struct net_device **hw_dev)
966 #ifdef CONFIG_NET_CLS_ACT
967 const struct tc_action *a;
970 if (tc_no_actions(exts))
973 tcf_exts_to_list(exts, &actions);
974 list_for_each_entry(a, &actions, list) {
975 if (a->ops->get_dev) {
976 a->ops->get_dev(a, dev_net(dev), hw_dev);
985 EXPORT_SYMBOL(tcf_exts_get_dev);
987 static int __init tc_filter_init(void)
989 rtnl_register(PF_UNSPEC, RTM_NEWTFILTER, tc_ctl_tfilter, NULL, NULL);
990 rtnl_register(PF_UNSPEC, RTM_DELTFILTER, tc_ctl_tfilter, NULL, NULL);
991 rtnl_register(PF_UNSPEC, RTM_GETTFILTER, tc_ctl_tfilter,
992 tc_dump_tfilter, NULL);
997 subsys_initcall(tc_filter_init);