diff options
author | Patrick McHardy <kaber@trash.net> | 2009-12-03 02:25:56 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-12-03 21:14:36 +0100 |
commit | 1b038a5e60c7812f19818e8a5df96d029e49c38f (patch) | |
tree | eea09368802178a64429beb656a03a2cc71e2f42 /include/net/fib_rules.h | |
parent | net 02/05: fib_rules: rename ifindex/ifname/FRA_IFNAME to iifindex/iifname/FR... (diff) | |
download | linux-1b038a5e60c7812f19818e8a5df96d029e49c38f.tar.xz linux-1b038a5e60c7812f19818e8a5df96d029e49c38f.zip |
net 03/05: fib_rules: add oif classification
commit 68144d350f4f6c348659c825cde6a82b34c27a91
Author: Patrick McHardy <kaber@trash.net>
Date: Thu Dec 3 12:05:25 2009 +0100
net: fib_rules: add oif classification
Support routing table lookup based on the flow's oif. This is useful to
classify packets originating from sockets bound to interfaces differently.
The route cache already includes the oif and needs no changes.
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/fib_rules.h')
-rw-r--r-- | include/net/fib_rules.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/net/fib_rules.h b/include/net/fib_rules.h index 62bebcb2a51c..d4e875a58f8b 100644 --- a/include/net/fib_rules.h +++ b/include/net/fib_rules.h @@ -11,6 +11,7 @@ struct fib_rule { struct list_head list; atomic_t refcnt; int iifindex; + int oifindex; u32 mark; u32 mark_mask; u32 pref; @@ -20,6 +21,7 @@ struct fib_rule { u32 target; struct fib_rule * ctarget; char iifname[IFNAMSIZ]; + char oifname[IFNAMSIZ]; struct rcu_head rcu; struct net * fr_net; }; @@ -68,6 +70,7 @@ struct fib_rules_ops { #define FRA_GENERIC_POLICY \ [FRA_IIFNAME] = { .type = NLA_STRING, .len = IFNAMSIZ - 1 }, \ + [FRA_OIFNAME] = { .type = NLA_STRING, .len = IFNAMSIZ - 1 }, \ [FRA_PRIORITY] = { .type = NLA_U32 }, \ [FRA_FWMARK] = { .type = NLA_U32 }, \ [FRA_FWMASK] = { .type = NLA_U32 }, \ |