From: Thomas Graf Date: Thu, 22 Mar 2007 18:56:22 +0000 (-0700) Subject: [PKT_SCHED] cls: Use rtnl registration interface X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=82623c0d73bd111cad26e501e509966b2455b0e0;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git [PKT_SCHED] cls: Use rtnl registration interface Signed-off-by: Thomas Graf Signed-off-by: David S. Miller --- diff --git a/net/sched/cls_api.c b/net/sched/cls_api.c index 3d0a6cdcaebc..ca3da5013b7a 100644 --- a/net/sched/cls_api.c +++ b/net/sched/cls_api.c @@ -29,7 +29,6 @@ #include #include #include -#include #include #include #include @@ -616,18 +615,11 @@ rtattr_failure: __attribute__ ((unused)) static int __init tc_filter_init(void) { - struct rtnetlink_link *link_p = rtnetlink_links[PF_UNSPEC]; + rtnl_register(PF_UNSPEC, RTM_NEWTFILTER, tc_ctl_tfilter, NULL); + rtnl_register(PF_UNSPEC, RTM_DELTFILTER, tc_ctl_tfilter, NULL); + rtnl_register(PF_UNSPEC, RTM_GETTFILTER, tc_ctl_tfilter, + tc_dump_tfilter); - /* Setup rtnetlink links. It is made here to avoid - exporting large number of public symbols. - */ - - if (link_p) { - link_p[RTM_NEWTFILTER-RTM_BASE].doit = tc_ctl_tfilter; - link_p[RTM_DELTFILTER-RTM_BASE].doit = tc_ctl_tfilter; - link_p[RTM_GETTFILTER-RTM_BASE].doit = tc_ctl_tfilter; - link_p[RTM_GETTFILTER-RTM_BASE].dumpit = tc_dump_tfilter; - } return 0; }