summaryrefslogtreecommitdiffstats
path: root/net/ipv6/af_inet6.c
diff options
context:
space:
mode:
authorEric W. Biederman <ebiederm@xmission.com>2008-01-10 12:25:28 +0100
committerDavid S. Miller <davem@davemloft.net>2008-01-29 00:01:27 +0100
commit6b175b26c1048d331508940ad3516ead1998084f (patch)
tree810b0a18cee4d87c573274fdfd4a59fc624cfed2 /net/ipv6/af_inet6.c
parent[NETNS]: Add netns parameter to fib_get_table/fib_new_table. (diff)
downloadlinux-6b175b26c1048d331508940ad3516ead1998084f.tar.xz
linux-6b175b26c1048d331508940ad3516ead1998084f.zip
[NETNS]: Add netns parameter to inet_(dev_)add_type.
The patch extends the inet_addr_type and inet_dev_addr_type with the network namespace pointer. That allows to access the different tables relatively to the network namespace. The modification of the signature function is reported in all the callers of the inet_addr_type using the pointer to the well known init_net. Acked-by: Benjamin Thery <benjamin.thery@bull.net> Acked-by: Daniel Lezcano <dlezcano@fr.ibm.com> Signed-off-by: Eric W. Biederman <ebiederm@xmission.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/af_inet6.c')
-rw-r--r--net/ipv6/af_inet6.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv6/af_inet6.c b/net/ipv6/af_inet6.c
index 218b8b3050a1..ac8772dd968f 100644
--- a/net/ipv6/af_inet6.c
+++ b/net/ipv6/af_inet6.c
@@ -280,7 +280,7 @@ int inet6_bind(struct socket *sock, struct sockaddr *uaddr, int addr_len)
/* Check if the address belongs to the host. */
if (addr_type == IPV6_ADDR_MAPPED) {
v4addr = addr->sin6_addr.s6_addr32[3];
- if (inet_addr_type(v4addr) != RTN_LOCAL) {
+ if (inet_addr_type(&init_net, v4addr) != RTN_LOCAL) {
err = -EADDRNOTAVAIL;
goto out;
}