aboutsummaryrefslogtreecommitdiff
path: root/sys/netinet/ip_carp.c
diff options
context:
space:
mode:
authorGleb Smirnoff <glebius@FreeBSD.org>2015-04-01 22:26:39 +0000
committerGleb Smirnoff <glebius@FreeBSD.org>2015-04-01 22:26:39 +0000
commit6d947416cc02a93c63479eed545059577446814c (patch)
tree8b00e7a494687331ff2fc1bd6aa72facdfb91310 /sys/netinet/ip_carp.c
parent703e4974aa45d77a4d683b07a2c8392c546703ca (diff)
downloadsrc-6d947416cc02a93c63479eed545059577446814c.tar.gz
src-6d947416cc02a93c63479eed545059577446814c.zip
o Use new function ip_fillid() in all places throughout the kernel,
where we want to create a new IP datagram. o Add support for RFC6864, which allows to set IP ID for atomic IP datagrams to any value, to improve performance. The behaviour is controlled by net.inet.ip.rfc6864 sysctl knob, which is enabled by default. o In case if we generate IP ID, use counter(9) to improve performance. o Gather all code related to IP ID into ip_id.c. Differential Revision: https://reviews.freebsd.org/D2177 Reviewed by: adrian, cy, rpaulo Tested by: Emeric POUPON <emeric.poupon stormshield.eu> Sponsored by: Netflix Sponsored by: Nginx, Inc. Relnotes: yes
Notes
Notes: svn path=/head/; revision=280971
Diffstat (limited to 'sys/netinet/ip_carp.c')
-rw-r--r--sys/netinet/ip_carp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/netinet/ip_carp.c b/sys/netinet/ip_carp.c
index 524ebd8443bb..20962b03d83c 100644
--- a/sys/netinet/ip_carp.c
+++ b/sys/netinet/ip_carp.c
@@ -838,11 +838,11 @@ carp_send_ad_locked(struct carp_softc *sc)
ip->ip_hl = sizeof(*ip) >> 2;
ip->ip_tos = IPTOS_LOWDELAY;
ip->ip_len = htons(len);
- ip->ip_id = ip_newid();
ip->ip_off = htons(IP_DF);
ip->ip_ttl = CARP_DFLTTL;
ip->ip_p = IPPROTO_CARP;
ip->ip_sum = 0;
+ ip_fillid(ip);
bzero(&sa, sizeof(sa));
sa.sa_family = AF_INET;