]> CyberLeo.Net >> Repos - FreeBSD/stable/8.git/commit
MFC r241406, r241502, r241884.
authormelifaro <melifaro@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Tue, 27 Nov 2012 20:16:37 +0000 (20:16 +0000)
committermelifaro <melifaro@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Tue, 27 Nov 2012 20:16:37 +0000 (20:16 +0000)
commitfd765e545ce1c120c649b321ac4fce60f146ff3e
tree305fb681e3f721796d5da5666c2cb501b2025b0b
parent7d0f0ccd13d472dfa140d74213b31909b0aad8b2
MFC r241406, r241502, r241884.

Do not check if found IPv4 rte is dynamic if net.inet.icmp.drop_redirect is
enabled. This eliminates one mtx_lock() per each routing lookup thus improving
performance in several cases (routing to directly connected interface or routing
to default gateway).

Icmp redirects should not be used to provide routing direction nowadays, even
for end hosts. Routers should not use them too (and this is explicitly restricted
in IPv6, see RFC 4861, clause 8.2).

Current commit changes rnh_machaddr function to 'stock' rn_match (and back) for every
AF_INET routing table in given VNET instance on drop_redirect sysctl change.

Eliminate code checking if found IPv6 rte is dynamic. IPv6 redirects
are using (different) ND-based approach described in RFC 4861. This change
is similar to r241406 which conditionally skips the same check in IPv4.

Cleanup documentation: cloning route support has been removed in r186119.

This change is part of bigger patch eliminating rte locking.

Sponsored by: Yandex LLC

git-svn-id: svn://svn.freebsd.org/base/stable/8@243629 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
sys/netinet/in_rmx.c
sys/netinet/in_var.h
sys/netinet/ip_icmp.c
sys/netinet/ip_var.h
sys/netinet6/in6_rmx.c