aboutsummaryrefslogtreecommitdiffstats
path: root/net/core/rtnetlink.c
diff options
context:
space:
mode:
authorThomas Graf <tgraf@suug.ch>2006-08-04 06:38:38 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2006-09-22 17:53:40 -0400
commit14c0b97ddfc2944982d078b8e33b088840068976 (patch)
tree41109287d7e143da29b4bc8742040582af17d870 /net/core/rtnetlink.c
parentc71099acce933455123ee505cc75964610a209ad (diff)
[NET]: Protocol Independant Policy Routing Rules Framework
Derived from net/ipv/fib_rules.c Signed-off-by: Thomas Graf <tgraf@suug.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core/rtnetlink.c')
-rw-r--r--net/core/rtnetlink.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c
index 30cc1ba6ed5c..aa7cff2257b1 100644
--- a/net/core/rtnetlink.c
+++ b/net/core/rtnetlink.c
@@ -49,6 +49,7 @@
49#include <net/udp.h> 49#include <net/udp.h>
50#include <net/sock.h> 50#include <net/sock.h>
51#include <net/pkt_sched.h> 51#include <net/pkt_sched.h>
52#include <net/fib_rules.h>
52#include <net/netlink.h> 53#include <net/netlink.h>
53#ifdef CONFIG_NET_WIRELESS_RTNETLINK 54#ifdef CONFIG_NET_WIRELESS_RTNETLINK
54#include <linux/wireless.h> 55#include <linux/wireless.h>
@@ -103,7 +104,7 @@ static const int rtm_min[RTM_NR_FAMILIES] =
103 [RTM_FAM(RTM_NEWADDR)] = NLMSG_LENGTH(sizeof(struct ifaddrmsg)), 104 [RTM_FAM(RTM_NEWADDR)] = NLMSG_LENGTH(sizeof(struct ifaddrmsg)),
104 [RTM_FAM(RTM_NEWROUTE)] = NLMSG_LENGTH(sizeof(struct rtmsg)), 105 [RTM_FAM(RTM_NEWROUTE)] = NLMSG_LENGTH(sizeof(struct rtmsg)),
105 [RTM_FAM(RTM_NEWNEIGH)] = NLMSG_LENGTH(sizeof(struct ndmsg)), 106 [RTM_FAM(RTM_NEWNEIGH)] = NLMSG_LENGTH(sizeof(struct ndmsg)),
106 [RTM_FAM(RTM_NEWRULE)] = NLMSG_LENGTH(sizeof(struct rtmsg)), 107 [RTM_FAM(RTM_NEWRULE)] = NLMSG_LENGTH(sizeof(struct fib_rule_hdr)),
107 [RTM_FAM(RTM_NEWQDISC)] = NLMSG_LENGTH(sizeof(struct tcmsg)), 108 [RTM_FAM(RTM_NEWQDISC)] = NLMSG_LENGTH(sizeof(struct tcmsg)),
108 [RTM_FAM(RTM_NEWTCLASS)] = NLMSG_LENGTH(sizeof(struct tcmsg)), 109 [RTM_FAM(RTM_NEWTCLASS)] = NLMSG_LENGTH(sizeof(struct tcmsg)),
109 [RTM_FAM(RTM_NEWTFILTER)] = NLMSG_LENGTH(sizeof(struct tcmsg)), 110 [RTM_FAM(RTM_NEWTFILTER)] = NLMSG_LENGTH(sizeof(struct tcmsg)),
@@ -120,7 +121,7 @@ static const int rta_max[RTM_NR_FAMILIES] =
120 [RTM_FAM(RTM_NEWADDR)] = IFA_MAX, 121 [RTM_FAM(RTM_NEWADDR)] = IFA_MAX,
121 [RTM_FAM(RTM_NEWROUTE)] = RTA_MAX, 122 [RTM_FAM(RTM_NEWROUTE)] = RTA_MAX,
122 [RTM_FAM(RTM_NEWNEIGH)] = NDA_MAX, 123 [RTM_FAM(RTM_NEWNEIGH)] = NDA_MAX,
123 [RTM_FAM(RTM_NEWRULE)] = RTA_MAX, 124 [RTM_FAM(RTM_NEWRULE)] = FRA_MAX,
124 [RTM_FAM(RTM_NEWQDISC)] = TCA_MAX, 125 [RTM_FAM(RTM_NEWQDISC)] = TCA_MAX,
125 [RTM_FAM(RTM_NEWTCLASS)] = TCA_MAX, 126 [RTM_FAM(RTM_NEWTCLASS)] = TCA_MAX,
126 [RTM_FAM(RTM_NEWTFILTER)] = TCA_MAX, 127 [RTM_FAM(RTM_NEWTFILTER)] = TCA_MAX,
@@ -757,6 +758,10 @@ static struct rtnetlink_link link_rtnetlink_table[RTM_NR_MSGTYPES] =
757 [RTM_NEWNEIGH - RTM_BASE] = { .doit = neigh_add }, 758 [RTM_NEWNEIGH - RTM_BASE] = { .doit = neigh_add },
758 [RTM_DELNEIGH - RTM_BASE] = { .doit = neigh_delete }, 759 [RTM_DELNEIGH - RTM_BASE] = { .doit = neigh_delete },
759 [RTM_GETNEIGH - RTM_BASE] = { .dumpit = neigh_dump_info }, 760 [RTM_GETNEIGH - RTM_BASE] = { .dumpit = neigh_dump_info },
761#ifdef CONFIG_FIB_RULES
762 [RTM_NEWRULE - RTM_BASE] = { .doit = fib_nl_newrule },
763 [RTM_DELRULE - RTM_BASE] = { .doit = fib_nl_delrule },
764#endif
760 [RTM_GETRULE - RTM_BASE] = { .dumpit = rtnetlink_dump_all }, 765 [RTM_GETRULE - RTM_BASE] = { .dumpit = rtnetlink_dump_all },
761 [RTM_GETNEIGHTBL - RTM_BASE] = { .dumpit = neightbl_dump_info }, 766 [RTM_GETNEIGHTBL - RTM_BASE] = { .dumpit = neightbl_dump_info },
762 [RTM_SETNEIGHTBL - RTM_BASE] = { .doit = neightbl_set }, 767 [RTM_SETNEIGHTBL - RTM_BASE] = { .doit = neightbl_set },