aboutsummaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorYOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>2007-11-14 15:55:29 +0900
committerDavid S. Miller <davem@davemloft.net>2008-01-28 14:53:56 -0800
commitc1ee656ccb3b03304d38f852debccdd1567702e6 (patch)
tree3debe7c94a5230709fe6705ac0f7036274983954 /net
parent294b4baf292197e13d1df1d253efa7ac84ffee3f (diff)
[IPV6] ADDRCONF: Rename ipv6_saddr_label() to ipv6_addr_label().
This patch renames ipv6_saddr_label() to ipv6_addr_label() because address label is used for both of source address and destination address. Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r--net/ipv6/addrconf.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
index c0720e4659b..733374b68d2 100644
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -875,7 +875,7 @@ static inline int ipv6_saddr_preferred(int type)
}
/* static matching label */
-static inline int ipv6_saddr_label(const struct in6_addr *addr, int type)
+static inline int ipv6_addr_label(const struct in6_addr *addr, int type)
{
/*
* prefix (longest match) label
@@ -910,7 +910,7 @@ int ipv6_dev_get_saddr(struct net_device *daddr_dev,
struct inet6_ifaddr *ifa_result = NULL;
int daddr_type = __ipv6_addr_type(daddr);
int daddr_scope = __ipv6_addr_src_scope(daddr_type);
- u32 daddr_label = ipv6_saddr_label(daddr, daddr_type);
+ u32 daddr_label = ipv6_addr_label(daddr, daddr_type);
struct net_device *dev;
memset(&hiscore, 0, sizeof(hiscore));
@@ -1083,11 +1083,13 @@ int ipv6_dev_get_saddr(struct net_device *daddr_dev,
/* Rule 6: Prefer matching label */
if (hiscore.rule < 6) {
- if (ipv6_saddr_label(&ifa_result->addr, hiscore.addr_type) == daddr_label)
+ if (ipv6_addr_label(&ifa_result->addr,
+ hiscore.addr_type) == daddr_label)
hiscore.attrs |= IPV6_SADDR_SCORE_LABEL;
hiscore.rule++;
}
- if (ipv6_saddr_label(&ifa->addr, score.addr_type) == daddr_label) {
+ if (ipv6_addr_label(&ifa->addr,
+ score.addr_type) == daddr_label) {
score.attrs |= IPV6_SADDR_SCORE_LABEL;
if (!(hiscore.attrs & IPV6_SADDR_SCORE_LABEL)) {
score.rule = 6;