summaryrefslogtreecommitdiffstats
path: root/sys/netinet6/nd6_rtr.c
diff options
context:
space:
mode:
authorbz <bz@FreeBSD.org>2010-04-29 11:52:42 +0000
committerbz <bz@FreeBSD.org>2010-04-29 11:52:42 +0000
commit0a90ef17283bc848eee90c3bdd5bec3fcc1bc879 (patch)
treee6f9695e24617b291f2a8f0b1f388eda2e605549 /sys/netinet6/nd6_rtr.c
parent043deeb56455e1129861bf93ec57f03b90200344 (diff)
downloadFreeBSD-src-0a90ef17283bc848eee90c3bdd5bec3fcc1bc879.zip
FreeBSD-src-0a90ef17283bc848eee90c3bdd5bec3fcc1bc879.tar.gz
MFP4: @176978-176982, 176984, 176990-176994, 177441
"Whitspace" churn after the VIMAGE/VNET whirls. Remove the need for some "init" functions within the network stack, like pim6_init(), icmp_init() or significantly shorten others like ip6_init() and nd6_init(), using static initialization again where possible and formerly missed. Move (most) variables back to the place they used to be before the container structs and VIMAGE_GLOABLS (before r185088) and try to reduce the diff to stable/7 and earlier as good as possible, to help out-of-tree consumers to update from 6.x or 7.x to 8 or 9. This also removes some header file pollution for putatively static global variables. Revert VIMAGE specific changes in ipfilter::ip_auth.c, that are no longer needed. Reviewed by: jhb Discussed with: rwatson Sponsored by: The FreeBSD Foundation Sponsored by: CK Software GmbH MFC after: 6 days
Diffstat (limited to 'sys/netinet6/nd6_rtr.c')
-rw-r--r--sys/netinet6/nd6_rtr.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/sys/netinet6/nd6_rtr.c b/sys/netinet6/nd6_rtr.c
index 74f4954..19ec989 100644
--- a/sys/netinet6/nd6_rtr.c
+++ b/sys/netinet6/nd6_rtr.c
@@ -90,14 +90,16 @@ VNET_DECLARE(int, nd6_recalc_reachtm_interval);
#define V_nd6_recalc_reachtm_interval VNET(nd6_recalc_reachtm_interval)
static VNET_DEFINE(struct ifnet *, nd6_defifp);
+VNET_DEFINE(int, nd6_defifindex);
#define V_nd6_defifp VNET(nd6_defifp)
-VNET_DEFINE(int, nd6_defifindex);
-VNET_DEFINE(int, ip6_use_tempaddr);
+VNET_DEFINE(int, ip6_use_tempaddr) = 0;
+
VNET_DEFINE(int, ip6_desync_factor);
-VNET_DEFINE(u_int32_t, ip6_temp_preferred_lifetime);
-VNET_DEFINE(u_int32_t, ip6_temp_valid_lifetime);
-VNET_DEFINE(int, ip6_temp_regen_advance);
+VNET_DEFINE(u_int32_t, ip6_temp_preferred_lifetime) = DEF_TEMP_PREFERRED_LIFETIME;
+VNET_DEFINE(u_int32_t, ip6_temp_valid_lifetime) = DEF_TEMP_VALID_LIFETIME;
+
+VNET_DEFINE(int, ip6_temp_regen_advance) = TEMPADDR_REGEN_ADVANCE;
/* RTPREF_MEDIUM has to be 0! */
#define RTPREF_HIGH 1
OpenPOWER on IntegriCloud