[Bluetooth] Use ACL config stage to retrieve remote features
[pandora-kernel.git] / net / ipv6 / af_inet6.c
index 12f04e9..e84b3fd 100644 (file)
@@ -61,6 +61,9 @@
 
 #include <asm/uaccess.h>
 #include <asm/system.h>
+#ifdef CONFIG_IPV6_MROUTE
+#include <linux/mroute6.h>
+#endif
 
 MODULE_AUTHOR("Cast of dozens");
 MODULE_DESCRIPTION("IPv6 protocol stack for Linux");
@@ -188,7 +191,7 @@ lookup_protocol:
        np->mcast_hops  = -1;
        np->mc_loop     = 1;
        np->pmtudisc    = IPV6_PMTUDISC_WANT;
-       np->ipv6only    = init_net.ipv6.sysctl.bindv6only;
+       np->ipv6only    = net->ipv6.sysctl.bindv6only;
 
        /* Init the ipv4 part of the socket since we can have sockets
         * using v6 API for ipv4.
@@ -862,11 +865,16 @@ static int inet6_net_init(struct net *net)
        err = tcp6_proc_init(net);
        if (err)
                goto proc_tcp6_fail;
+       err = ac6_proc_init(net);
+       if (err)
+               goto proc_ac6_fail;
 out:
 #endif
        return err;
 
 #ifdef CONFIG_PROC_FS
+proc_ac6_fail:
+       tcp6_proc_exit(net);
 proc_tcp6_fail:
        udp6_proc_exit(net);
        goto out;
@@ -878,6 +886,7 @@ static void inet6_net_exit(struct net *net)
 #ifdef CONFIG_PROC_FS
        udp6_proc_exit(net);
        tcp6_proc_exit(net);
+       ac6_proc_exit(net);
 #endif
 }
 
@@ -947,6 +956,9 @@ static int __init inet6_init(void)
        err = icmpv6_init();
        if (err)
                goto icmp_fail;
+#ifdef CONFIG_IPV6_MROUTE
+       ip6_mr_init();
+#endif
        err = ndisc_init();
        if (err)
                goto ndisc_fail;
@@ -965,9 +977,6 @@ static int __init inet6_init(void)
                goto proc_udplite6_fail;
        if (ipv6_misc_proc_init())
                goto proc_misc6_fail;
-
-       if (ac6_proc_init())
-               goto proc_anycast6_fail;
        if (if6_proc_init())
                goto proc_if6_fail;
 #endif
@@ -1039,8 +1048,6 @@ ip6_route_fail:
 #ifdef CONFIG_PROC_FS
        if6_proc_exit();
 proc_if6_fail:
-       ac6_proc_exit();
-proc_anycast6_fail:
        ipv6_misc_proc_exit();
 proc_misc6_fail:
        udplite6_proc_exit();
@@ -1101,7 +1108,6 @@ static void __exit inet6_exit(void)
 
        /* Cleanup code parts. */
        if6_proc_exit();
-       ac6_proc_exit();
        ipv6_misc_proc_exit();
        udplite6_proc_exit();
        raw6_proc_exit();