diff options
author | YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org> | 2008-03-10 10:00:30 (GMT) |
---|---|---|
committer | YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org> | 2008-03-25 01:24:00 (GMT) |
commit | 6b75d0908185bf853b188afa6f269426f6554c5b (patch) | |
tree | 85f28296077f3d873bbda249dc0eafcc911164fd /net/ipv6/udp.c | |
parent | 4725474584d6aa2f07b3d47442dfbc4f6544f65e (diff) | |
download | linux-fsl-qoriq-6b75d0908185bf853b188afa6f269426f6554c5b.tar.xz |
[IPV6]: Optimize hop-limit determination.
Last part of hop-limit determination is always:
hoplimit = dst_metric(dst, RTAX_HOPLIMIT);
if (hoplimit < 0)
hoplimit = ipv6_get_hoplimit(dst->dev).
Let's consolidate it as ip6_dst_hoplimit(dst).
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Diffstat (limited to 'net/ipv6/udp.c')
-rw-r--r-- | net/ipv6/udp.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c index 5f5d121..593d3ef 100644 --- a/net/ipv6/udp.c +++ b/net/ipv6/udp.c @@ -792,9 +792,7 @@ do_udp_sendmsg: else hlimit = np->hop_limit; if (hlimit < 0) - hlimit = dst_metric(dst, RTAX_HOPLIMIT); - if (hlimit < 0) - hlimit = ipv6_get_hoplimit(dst->dev); + hlimit = ip6_dst_hoplimit(dst); } if (tclass < 0) { |