diff options
author | Denis V. Lunev <den@openvz.org> | 2008-01-10 06:17:29 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-28 18:01:21 -0500 |
commit | f8c26b8d589867aed8251db2935f8aa03aa68717 (patch) | |
tree | a96938be9494e60365d10c652cb3e7c9d3dcee18 /net/core | |
parent | 41a76906b3225997036efd88cbaae69d60b1e947 (diff) |
[NETNS]: Add netns parameter to fib_rules_(un)register.
The patch extends the different fib rules API in order to pass the
network namespace pointer. That will allow to access the different
tables from a namespace relative object. As usual, the pointer to the
init_net variable is passed as parameter so we don't break the
network.
Acked-by: Benjamin Thery <benjamin.thery@bull.net>
Acked-by: Daniel Lezcano <dlezcano@fr.ibm.com>
Signed-off-by: Denis V. Lunev <den@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core')
-rw-r--r-- | net/core/fib_rules.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/core/fib_rules.c b/net/core/fib_rules.c index fcbf41c0a5d4..ada9c8155e3c 100644 --- a/net/core/fib_rules.c +++ b/net/core/fib_rules.c | |||
@@ -74,7 +74,7 @@ static void flush_route_cache(struct fib_rules_ops *ops) | |||
74 | ops->flush_cache(); | 74 | ops->flush_cache(); |
75 | } | 75 | } |
76 | 76 | ||
77 | int fib_rules_register(struct fib_rules_ops *ops) | 77 | int fib_rules_register(struct net *net, struct fib_rules_ops *ops) |
78 | { | 78 | { |
79 | int err = -EEXIST; | 79 | int err = -EEXIST; |
80 | struct fib_rules_ops *o; | 80 | struct fib_rules_ops *o; |
@@ -113,7 +113,7 @@ void fib_rules_cleanup_ops(struct fib_rules_ops *ops) | |||
113 | } | 113 | } |
114 | EXPORT_SYMBOL_GPL(fib_rules_cleanup_ops); | 114 | EXPORT_SYMBOL_GPL(fib_rules_cleanup_ops); |
115 | 115 | ||
116 | int fib_rules_unregister(struct fib_rules_ops *ops) | 116 | int fib_rules_unregister(struct net *net, struct fib_rules_ops *ops) |
117 | { | 117 | { |
118 | int err = 0; | 118 | int err = 0; |
119 | struct fib_rules_ops *o; | 119 | struct fib_rules_ops *o; |