diff options
author | Cong Wang <xiyou.wangcong@gmail.com> | 2013-05-22 05:52:22 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-05-23 01:17:47 -0700 |
commit | 8892475386e819aa50856947948c546ccc964d96 (patch) | |
tree | d57da7a52c21a84ba6555a3f3dcd9f17e43a100c /net/ipv6/addrconf.c | |
parent | 7996c799ae329fab1b9c8d475fd08883f0499ed9 (diff) | |
download | linux-8892475386e819aa50856947948c546ccc964d96.tar.bz2 |
ipv6: use ipv6_addr_scope() helper
ipv6_addr_type(&addr)&IPV6_ADDR_SCOPE_MASK could be replaced
by ipv6_addr_scope(), which is slightly faster.
Cc: Hideaki YOSHIFUJI <yoshfuji@linux-ipv6.org>
Cc: David S. Miller <davem@davemloft.net>
Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/addrconf.c')
-rw-r--r-- | net/ipv6/addrconf.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c index e05269647c2b..432e084b6b62 100644 --- a/net/ipv6/addrconf.c +++ b/net/ipv6/addrconf.c @@ -1126,8 +1126,7 @@ retry: ift = !max_addresses || ipv6_count_addresses(idev) < max_addresses ? - ipv6_add_addr(idev, &addr, tmp_plen, - ipv6_addr_type(&addr)&IPV6_ADDR_SCOPE_MASK, + ipv6_add_addr(idev, &addr, tmp_plen, ipv6_addr_scope(&addr), addr_flags) : NULL; if (IS_ERR_OR_NULL(ift)) { in6_ifa_put(ifp); |