]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
[NETNS][IPV6] route6 - Pass the network namespace parameter to rt6_purge_dflt_routers
authorDaniel Lezcano <dlezcano@fr.ibm.com>
Tue, 4 Mar 2008 21:47:14 +0000 (13:47 -0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 4 Mar 2008 21:47:14 +0000 (13:47 -0800)
Add a network namespace parameter to rt6_purge_dflt_routers.  This is
needed to call fib6_get_table with the appropriate network namespace.

Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
Signed-off-by: Benjamin Thery <benjamin.thery@bull.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/ip6_route.h
net/ipv6/addrconf.c
net/ipv6/route.c

index 92004c5160c700287258d7f9d2cdfe95e9d6cd11..1444d358836d5415b7869ea2c8cd8215a334ce92 100644 (file)
@@ -95,7 +95,7 @@ extern struct rt6_info *      rt6_add_dflt_router(struct in6_addr *gwaddr,
                                                    struct net_device *dev,
                                                    unsigned int pref);
 
-extern void                    rt6_purge_dflt_routers(void);
+extern void                    rt6_purge_dflt_routers(struct net *net);
 
 extern int                     rt6_route_rcv(struct net_device *dev,
                                              u8 *opt, int len,
index 9d894e8c7b724aff0be59207717c471e1e3b1e15..b37ae421b61bf9048bd2144a201941d9a48b8f12 100644 (file)
@@ -493,7 +493,7 @@ static void addrconf_fixup_forwarding(struct ctl_table *table, int *p, int old)
                dev_forward_change((struct inet6_dev *)table->extra1);
 
        if (*p)
-               rt6_purge_dflt_routers();
+               rt6_purge_dflt_routers(net);
 }
 #endif
 
index 4278cec522c5b842d44a83170b38fef29460365b..ad3d684e544ae0c114bd11199fb4596bf9a09491 100644 (file)
@@ -1697,13 +1697,13 @@ struct rt6_info *rt6_add_dflt_router(struct in6_addr *gwaddr,
        return rt6_get_dflt_router(gwaddr, dev);
 }
 
-void rt6_purge_dflt_routers(void)
+void rt6_purge_dflt_routers(struct net *net)
 {
        struct rt6_info *rt;
        struct fib6_table *table;
 
        /* NOTE: Keep consistent with rt6_get_dflt_router */
-       table = fib6_get_table(&init_net, RT6_TABLE_DFLT);
+       table = fib6_get_table(net, RT6_TABLE_DFLT);
        if (table == NULL)
                return;