diff options
author | David S. Miller <davem@davemloft.net> | 2013-08-16 18:37:26 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-08-16 18:37:26 -0400 |
commit | 2ff1cf12c9fe70e75e600404e6a4274b19d293ed (patch) | |
tree | beafddac0a8098e3f07d2ec60e44a2a7d006e605 /net/ipv6/ip6_fib.c | |
parent | 16b304f3404f8e0243d5ee2b70b68767b7b59b2b (diff) | |
parent | 0f7dd1aa8f959216f1faa71513b9d3c1a9065e5a (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Diffstat (limited to 'net/ipv6/ip6_fib.c')
-rw-r--r-- | net/ipv6/ip6_fib.c | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/net/ipv6/ip6_fib.c b/net/ipv6/ip6_fib.c index ed828d6f37b2..73db48eba1c4 100644 --- a/net/ipv6/ip6_fib.c +++ b/net/ipv6/ip6_fib.c | |||
@@ -993,14 +993,22 @@ static struct fib6_node * fib6_lookup_1(struct fib6_node *root, | |||
993 | 993 | ||
994 | if (ipv6_prefix_equal(&key->addr, args->addr, key->plen)) { | 994 | if (ipv6_prefix_equal(&key->addr, args->addr, key->plen)) { |
995 | #ifdef CONFIG_IPV6_SUBTREES | 995 | #ifdef CONFIG_IPV6_SUBTREES |
996 | if (fn->subtree) | 996 | if (fn->subtree) { |
997 | fn = fib6_lookup_1(fn->subtree, args + 1); | 997 | struct fib6_node *sfn; |
998 | sfn = fib6_lookup_1(fn->subtree, | ||
999 | args + 1); | ||
1000 | if (!sfn) | ||
1001 | goto backtrack; | ||
1002 | fn = sfn; | ||
1003 | } | ||
998 | #endif | 1004 | #endif |
999 | if (!fn || fn->fn_flags & RTN_RTINFO) | 1005 | if (fn->fn_flags & RTN_RTINFO) |
1000 | return fn; | 1006 | return fn; |
1001 | } | 1007 | } |
1002 | } | 1008 | } |
1003 | 1009 | #ifdef CONFIG_IPV6_SUBTREES | |
1010 | backtrack: | ||
1011 | #endif | ||
1004 | if (fn->fn_flags & RTN_ROOT) | 1012 | if (fn->fn_flags & RTN_ROOT) |
1005 | break; | 1013 | break; |
1006 | 1014 | ||