Commit 94c77bb4 authored by Martin KaFai Lau's avatar Martin KaFai Lau Committed by David S. Miller
Browse files

ipv6: Avoid redoing fib6_lookup() for RTF_CACHE hit case

When there is a RTF_CACHE hit, no need to redo fib6_lookup()
with reachable=0.

Cc: David Miller <>
Cc: Hannes Frederic Sowa <>
Signed-off-by: default avatarMartin KaFai Lau <>
Signed-off-by: default avatarDavid S. Miller <>
parent a3c00e46
......@@ -944,12 +944,12 @@ redo_rt6_select:
goto out;
if (rt->rt6i_flags & RTF_CACHE)
goto out;
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))
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment