diff options
| author | Li RongQing <roy.qing.li@gmail.com> | 2013-12-22 20:32:38 -0500 |
|---|---|---|
| committer | David S. Miller <davem@davemloft.net> | 2013-12-31 13:37:46 -0500 |
| commit | 46306b49349ba9c4e5bdb9cb3c4e8b50192106bf (patch) | |
| tree | 1b2bcc4aba73b48f7f320a8cee203bd0929d7554 | |
| parent | 71a1d9ee103dc4c0dc9e534ee19bc92ceef0024b (diff) | |
ipv6: unneccessary to get address prefix in addrconf_get_prefix_route
Since addrconf_get_prefix_route inputs the address prefix to fib6_locate,
which does not uses the data which is out of the prefix_len length,
so do not need to use ipv6_addr_prefix to get address prefix.
Signed-off-by: Li RongQing <roy.qing.li@gmail.com>
Acked-by: Hannes Frederic Sowa <hannes@stressinduktion.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
| -rw-r--r-- | net/ipv6/addrconf.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c index cd2d7d0fb558..9418ca375132 100644 --- a/net/ipv6/addrconf.c +++ b/net/ipv6/addrconf.c | |||
| @@ -995,12 +995,9 @@ static void ipv6_del_addr(struct inet6_ifaddr *ifp) | |||
| 995 | * --yoshfuji | 995 | * --yoshfuji |
| 996 | */ | 996 | */ |
| 997 | if ((ifp->flags & IFA_F_PERMANENT) && onlink < 1) { | 997 | if ((ifp->flags & IFA_F_PERMANENT) && onlink < 1) { |
| 998 | struct in6_addr prefix; | ||
| 999 | struct rt6_info *rt; | 998 | struct rt6_info *rt; |
| 1000 | 999 | ||
| 1001 | ipv6_addr_prefix(&prefix, &ifp->addr, ifp->prefix_len); | 1000 | rt = addrconf_get_prefix_route(&ifp->addr, |
| 1002 | |||
| 1003 | rt = addrconf_get_prefix_route(&prefix, | ||
| 1004 | ifp->prefix_len, | 1001 | ifp->prefix_len, |
| 1005 | ifp->idev->dev, | 1002 | ifp->idev->dev, |
| 1006 | 0, RTF_GATEWAY | RTF_DEFAULT); | 1003 | 0, RTF_GATEWAY | RTF_DEFAULT); |
