projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a3c00e4
)
ipv6: Avoid redoing fib6_lookup() for RTF_CACHE hit case
author
Martin KaFai Lau
<
[email protected]
>
Mon, 20 Oct 2014 20:42:44 +0000
(13:42 -0700)
committer
David S. Miller
<
[email protected]
>
Fri, 24 Oct 2014 04:14:39 +0000
(
00:14
-0400)
When there is a RTF_CACHE hit, no need to redo fib6_lookup()
with reachable=0.
Cc: David Miller <
[email protected]
>
Cc: Hannes Frederic Sowa <
[email protected]
>
Signed-off-by: Martin KaFai Lau <
[email protected]
>
Signed-off-by: David S. Miller <
[email protected]
>
net/ipv6/route.c
patch
|
blob
|
history
diff --git
a/net/ipv6/route.c
b/net/ipv6/route.c
index f1ab2f4f4529d73d4e233c88355eda5311e88b88..98c523f4a3c37decd22e3efc48a4b70cd9fb33b8 100644
(file)
--- a/
net/ipv6/route.c
+++ b/
net/ipv6/route.c
@@
-944,12
+944,12
@@
redo_rt6_select:
goto out;
}
- if (rt->rt6i_flags & RTF_CACHE)
- goto out;
-
dst_hold(&rt->dst);
read_unlock_bh(&table->tb6_lock);
+ if (rt->rt6i_flags & RTF_CACHE)
+ goto out2;
+
if (!(rt->rt6i_flags & (RTF_NONEXTHOP | RTF_GATEWAY)))
nrt = rt6_alloc_cow(rt, &fl6->daddr, &fl6->saddr);
else if (!(rt->dst.flags & DST_HOST))