From owner-svn-src-all@FreeBSD.ORG Sun Nov 14 20:38:12 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 52987106564A; Sun, 14 Nov 2010 20:38:12 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3EC2B8FC13; Sun, 14 Nov 2010 20:38:12 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id oAEKcCX3093173; Sun, 14 Nov 2010 20:38:12 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id oAEKcB9M093130; Sun, 14 Nov 2010 20:38:11 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201011142038.oAEKcB9M093130@svn.freebsd.org> From: Dimitry Andric Date: Sun, 14 Nov 2010 20:38:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r215317 - in head/sys: kern mips/mips mips/rmi net netgraph netinet netinet/ipfw netinet6 netipsec powerpc/aim powerpc/booke X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 14 Nov 2010 20:38:12 -0000 Author: dim Date: Sun Nov 14 20:38:11 2010 New Revision: 215317 URL: http://svn.freebsd.org/changeset/base/215317 Log: Apply the STATIC_VNET_DEFINE and STATIC_DPCPU_DEFINE macros throughout the tree. Modified: head/sys/kern/kern_clock.c head/sys/kern/kern_clocksource.c head/sys/kern/sched_4bsd.c head/sys/kern/subr_pcpu.c head/sys/mips/mips/tick.c head/sys/mips/rmi/tick.c head/sys/net/flowtable.c head/sys/net/if.c head/sys/net/if_clone.c head/sys/net/if_ethersubr.c head/sys/net/if_gif.c head/sys/net/if_llatbl.c head/sys/net/if_loop.c head/sys/net/route.c head/sys/net/vnet.c head/sys/netgraph/ng_base.c head/sys/netgraph/ng_eiface.c head/sys/netgraph/ng_iface.c head/sys/netinet/if_ether.c head/sys/netinet/igmp.c head/sys/netinet/in.c head/sys/netinet/in_pcb.c head/sys/netinet/in_rmx.c head/sys/netinet/ip_divert.c head/sys/netinet/ip_fastfwd.c head/sys/netinet/ip_icmp.c head/sys/netinet/ip_input.c head/sys/netinet/ip_ipsec.c head/sys/netinet/ip_mroute.c head/sys/netinet/ipfw/ip_fw2.c head/sys/netinet/ipfw/ip_fw_dynamic.c head/sys/netinet/ipfw/ip_fw_nat.c head/sys/netinet/ipfw/ip_fw_pfil.c head/sys/netinet/siftr.c head/sys/netinet/tcp_hostcache.c head/sys/netinet/tcp_reass.c head/sys/netinet/tcp_subr.c head/sys/netinet/tcp_syncache.c head/sys/netinet/tcp_timewait.c head/sys/netinet/udp_usrreq.c head/sys/netinet6/frag6.c head/sys/netinet6/icmp6.c head/sys/netinet6/in6_rmx.c head/sys/netinet6/in6_src.c head/sys/netinet6/ip6_ipsec.c head/sys/netinet6/ip6_mroute.c head/sys/netinet6/mld6.c head/sys/netinet6/nd6.c head/sys/netinet6/nd6_nbr.c head/sys/netinet6/nd6_rtr.c head/sys/netinet6/scope6.c head/sys/netinet6/send.c head/sys/netipsec/key.c head/sys/netipsec/keysock.c head/sys/netipsec/xform_esp.c head/sys/powerpc/aim/clock.c head/sys/powerpc/booke/clock.c Modified: head/sys/kern/kern_clock.c ============================================================================== --- head/sys/kern/kern_clock.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/kern/kern_clock.c Sun Nov 14 20:38:11 2010 (r215317) @@ -373,7 +373,7 @@ int profprocs; int ticks; int psratio; -static DPCPU_DEFINE(int, pcputicks); /* Per-CPU version of ticks. */ +STATIC_DPCPU_DEFINE(int, pcputicks); /* Per-CPU version of ticks. */ static int global_hardclock_run = 0; /* Modified: head/sys/kern/kern_clocksource.c ============================================================================== --- head/sys/kern/kern_clocksource.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/kern/kern_clocksource.c Sun Nov 14 20:38:11 2010 (r215317) @@ -135,7 +135,7 @@ struct pcpu_state { int idle; /* This CPU is in idle mode. */ }; -static DPCPU_DEFINE(struct pcpu_state, timerstate); +STATIC_DPCPU_DEFINE(struct pcpu_state, timerstate); #define FREQ2BT(freq, bt) \ { \ Modified: head/sys/kern/sched_4bsd.c ============================================================================== --- head/sys/kern/sched_4bsd.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/kern/sched_4bsd.c Sun Nov 14 20:38:11 2010 (r215317) @@ -161,7 +161,7 @@ struct pcpuidlestat { u_int idlecalls; u_int oldidlecalls; }; -static DPCPU_DEFINE(struct pcpuidlestat, idlestat); +STATIC_DPCPU_DEFINE(struct pcpuidlestat, idlestat); static void setup_runqs(void) Modified: head/sys/kern/subr_pcpu.c ============================================================================== --- head/sys/kern/subr_pcpu.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/kern/subr_pcpu.c Sun Nov 14 20:38:11 2010 (r215317) @@ -70,7 +70,7 @@ struct dpcpu_free { TAILQ_ENTRY(dpcpu_free) df_link; }; -static DPCPU_DEFINE(char, modspace[DPCPU_MODMIN]); +STATIC_DPCPU_DEFINE(char, modspace[DPCPU_MODMIN]); static TAILQ_HEAD(, dpcpu_free) dpcpu_head = TAILQ_HEAD_INITIALIZER(dpcpu_head); static struct sx dpcpu_lock; uintptr_t dpcpu_off[MAXCPU]; Modified: head/sys/mips/mips/tick.c ============================================================================== --- head/sys/mips/mips/tick.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/mips/mips/tick.c Sun Nov 14 20:38:11 2010 (r215317) @@ -57,13 +57,13 @@ uint64_t counter_freq; struct timecounter *platform_timecounter; -static DPCPU_DEFINE(uint32_t, cycles_per_tick); +STATIC_DPCPU_DEFINE(uint32_t, cycles_per_tick); static uint32_t cycles_per_usec; -static DPCPU_DEFINE(volatile uint32_t, counter_upper); -static DPCPU_DEFINE(volatile uint32_t, counter_lower_last); -static DPCPU_DEFINE(uint32_t, compare_ticks); -static DPCPU_DEFINE(uint32_t, lost_ticks); +STATIC_DPCPU_DEFINE(volatile uint32_t, counter_upper); +STATIC_DPCPU_DEFINE(volatile uint32_t, counter_lower_last); +STATIC_DPCPU_DEFINE(uint32_t, compare_ticks); +STATIC_DPCPU_DEFINE(uint32_t, lost_ticks); struct clock_softc { int intr_rid; Modified: head/sys/mips/rmi/tick.c ============================================================================== --- head/sys/mips/rmi/tick.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/mips/rmi/tick.c Sun Nov 14 20:38:11 2010 (r215317) @@ -59,13 +59,13 @@ uint64_t counter_freq; struct timecounter *platform_timecounter; -static DPCPU_DEFINE(uint32_t, cycles_per_tick); +STATIC_DPCPU_DEFINE(uint32_t, cycles_per_tick); static uint32_t cycles_per_usec; -static DPCPU_DEFINE(volatile uint32_t, counter_upper); -static DPCPU_DEFINE(volatile uint32_t, counter_lower_last); -static DPCPU_DEFINE(uint32_t, compare_ticks); -static DPCPU_DEFINE(uint32_t, lost_ticks); +STATIC_DPCPU_DEFINE(volatile uint32_t, counter_upper); +STATIC_DPCPU_DEFINE(volatile uint32_t, counter_lower_last); +STATIC_DPCPU_DEFINE(uint32_t, compare_ticks); +STATIC_DPCPU_DEFINE(uint32_t, lost_ticks); struct clock_softc { int intr_rid; Modified: head/sys/net/flowtable.c ============================================================================== --- head/sys/net/flowtable.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/net/flowtable.c Sun Nov 14 20:38:11 2010 (r215317) @@ -184,10 +184,10 @@ struct flowtable { } __aligned(CACHE_LINE_SIZE); static struct proc *flowcleanerproc; -static VNET_DEFINE(struct flowtable *, flow_list_head); -static VNET_DEFINE(uint32_t, flow_hashjitter); -static VNET_DEFINE(uma_zone_t, flow_ipv4_zone); -static VNET_DEFINE(uma_zone_t, flow_ipv6_zone); +STATIC_VNET_DEFINE(struct flowtable *, flow_list_head); +STATIC_VNET_DEFINE(uint32_t, flow_hashjitter); +STATIC_VNET_DEFINE(uma_zone_t, flow_ipv4_zone); +STATIC_VNET_DEFINE(uma_zone_t, flow_ipv6_zone); #define V_flow_list_head VNET(flow_list_head) #define V_flow_hashjitter VNET(flow_hashjitter) @@ -230,13 +230,13 @@ do { \ * - idetach() cleanup for options VIMAGE builds. */ VNET_DEFINE(int, flowtable_enable) = 1; -static VNET_DEFINE(int, flowtable_debug); -static VNET_DEFINE(int, flowtable_syn_expire) = SYN_IDLE; -static VNET_DEFINE(int, flowtable_udp_expire) = UDP_IDLE; -static VNET_DEFINE(int, flowtable_fin_wait_expire) = FIN_WAIT_IDLE; -static VNET_DEFINE(int, flowtable_tcp_expire) = TCP_IDLE; -static VNET_DEFINE(int, flowtable_nmbflows); -static VNET_DEFINE(int, flowtable_ready) = 0; +STATIC_VNET_DEFINE(int, flowtable_debug); +STATIC_VNET_DEFINE(int, flowtable_syn_expire) = SYN_IDLE; +STATIC_VNET_DEFINE(int, flowtable_udp_expire) = UDP_IDLE; +STATIC_VNET_DEFINE(int, flowtable_fin_wait_expire) = FIN_WAIT_IDLE; +STATIC_VNET_DEFINE(int, flowtable_tcp_expire) = TCP_IDLE; +STATIC_VNET_DEFINE(int, flowtable_nmbflows); +STATIC_VNET_DEFINE(int, flowtable_ready) = 0; #define V_flowtable_enable VNET(flowtable_enable) #define V_flowtable_debug VNET(flowtable_debug) Modified: head/sys/net/if.c ============================================================================== --- head/sys/net/if.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/net/if.c Sun Nov 14 20:38:11 2010 (r215317) @@ -183,7 +183,7 @@ int ifqmaxlen = IFQ_MAXLEN; VNET_DEFINE(struct ifnethead, ifnet); /* depend on static init XXX */ VNET_DEFINE(struct ifgrouphead, ifg_head); -static VNET_DEFINE(int, if_indexlim) = 8; +STATIC_VNET_DEFINE(int, if_indexlim) = 8; /* Table of ifnet by index. */ VNET_DEFINE(struct ifindex_entry *, ifindex_table); Modified: head/sys/net/if_clone.c ============================================================================== --- head/sys/net/if_clone.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/net/if_clone.c Sun Nov 14 20:38:11 2010 (r215317) @@ -56,7 +56,7 @@ static int if_clone_createif(struct if_c caddr_t params); static struct mtx if_cloners_mtx; -static VNET_DEFINE(int, if_cloners_count); +STATIC_VNET_DEFINE(int, if_cloners_count); VNET_DEFINE(LIST_HEAD(, if_clone), if_cloners); #define V_if_cloners_count VNET(if_cloners_count) Modified: head/sys/net/if_ethersubr.c ============================================================================== --- head/sys/net/if_ethersubr.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/net/if_ethersubr.c Sun Nov 14 20:38:11 2010 (r215317) @@ -144,7 +144,7 @@ MALLOC_DEFINE(M_ARPCOM, "arpcom", "802.* #if defined(INET) || defined(INET6) int ether_ipfw_chk(struct mbuf **m0, struct ifnet *dst, int shared); -static VNET_DEFINE(int, ether_ipfw); +STATIC_VNET_DEFINE(int, ether_ipfw); #define V_ether_ipfw VNET(ether_ipfw) #endif Modified: head/sys/net/if_gif.c ============================================================================== --- head/sys/net/if_gif.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/net/if_gif.c Sun Nov 14 20:38:11 2010 (r215317) @@ -94,7 +94,7 @@ */ static struct mtx gif_mtx; static MALLOC_DEFINE(M_GIF, "gif", "Generic Tunnel Interface"); -static VNET_DEFINE(LIST_HEAD(, gif_softc), gif_softc_list); +STATIC_VNET_DEFINE(LIST_HEAD(, gif_softc), gif_softc_list); #define V_gif_softc_list VNET(gif_softc_list) void (*ng_gif_input_p)(struct ifnet *ifp, struct mbuf **mp, int af); @@ -124,7 +124,7 @@ SYSCTL_NODE(_net_link, IFT_GIF, gif, CTL */ #define MAX_GIF_NEST 1 #endif -static VNET_DEFINE(int, max_gif_nesting) = MAX_GIF_NEST; +STATIC_VNET_DEFINE(int, max_gif_nesting) = MAX_GIF_NEST; #define V_max_gif_nesting VNET(max_gif_nesting) SYSCTL_VNET_INT(_net_link_gif, OID_AUTO, max_nesting, CTLFLAG_RW, &VNET_NAME(max_gif_nesting), 0, "Max nested tunnels"); @@ -135,9 +135,9 @@ SYSCTL_VNET_INT(_net_link_gif, OID_AUTO, * we allow control over this check here. */ #ifdef XBONEHACK -static VNET_DEFINE(int, parallel_tunnels) = 1; +STATIC_VNET_DEFINE(int, parallel_tunnels) = 1; #else -static VNET_DEFINE(int, parallel_tunnels) = 0; +STATIC_VNET_DEFINE(int, parallel_tunnels) = 0; #endif #define V_parallel_tunnels VNET(parallel_tunnels) SYSCTL_VNET_INT(_net_link_gif, OID_AUTO, parallel_tunnels, CTLFLAG_RW, Modified: head/sys/net/if_llatbl.c ============================================================================== --- head/sys/net/if_llatbl.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/net/if_llatbl.c Sun Nov 14 20:38:11 2010 (r215317) @@ -62,7 +62,7 @@ __FBSDID("$FreeBSD$"); MALLOC_DEFINE(M_LLTABLE, "lltable", "link level address tables"); -static VNET_DEFINE(SLIST_HEAD(, lltable), lltables); +STATIC_VNET_DEFINE(SLIST_HEAD(, lltable), lltables); #define V_lltables VNET(lltables) extern void arprequest(struct ifnet *, struct in_addr *, struct in_addr *, Modified: head/sys/net/if_loop.c ============================================================================== --- head/sys/net/if_loop.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/net/if_loop.c Sun Nov 14 20:38:11 2010 (r215317) @@ -106,8 +106,8 @@ static void lo_clone_destroy(struct ifne VNET_DEFINE(struct ifnet *, loif); /* Used externally */ #ifdef VIMAGE -static VNET_DEFINE(struct ifc_simple_data, lo_cloner_data); -static VNET_DEFINE(struct if_clone, lo_cloner); +STATIC_VNET_DEFINE(struct ifc_simple_data, lo_cloner_data); +STATIC_VNET_DEFINE(struct if_clone, lo_cloner); #define V_lo_cloner_data VNET(lo_cloner_data) #define V_lo_cloner VNET(lo_cloner) #endif Modified: head/sys/net/route.c ============================================================================== --- head/sys/net/route.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/net/route.c Sun Nov 14 20:38:11 2010 (r215317) @@ -113,7 +113,7 @@ VNET_DEFINE(int, rttrash); /* routes no */ #define RNTORT(p) ((struct rtentry *)(p)) -static VNET_DEFINE(uma_zone_t, rtzone); /* Routing table UMA zone. */ +STATIC_VNET_DEFINE(uma_zone_t, rtzone); /* Routing table UMA zone. */ #define V_rtzone VNET(rtzone) #if 0 Modified: head/sys/net/vnet.c ============================================================================== --- head/sys/net/vnet.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/net/vnet.c Sun Nov 14 20:38:11 2010 (r215317) @@ -177,7 +177,7 @@ MALLOC_DEFINE(M_VNET_DATA, "vnet_data", * Space to store virtualized global variables from loadable kernel modules, * and the free list to manage it. */ -static VNET_DEFINE(char, modspace[VNET_MODMIN]); +STATIC_VNET_DEFINE(char, modspace[VNET_MODMIN]); /* * Global lists of subsystem constructor and destructors for vnets. They are Modified: head/sys/netgraph/ng_base.c ============================================================================== --- head/sys/netgraph/ng_base.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netgraph/ng_base.c Sun Nov 14 20:38:11 2010 (r215317) @@ -171,7 +171,7 @@ static struct mtx ng_typelist_mtx; /* Hash related definitions */ /* XXX Don't need to initialise them because it's a LIST */ -static VNET_DEFINE(LIST_HEAD(, ng_node), ng_ID_hash[NG_ID_HASH_SIZE]); +STATIC_VNET_DEFINE(LIST_HEAD(, ng_node), ng_ID_hash[NG_ID_HASH_SIZE]); #define V_ng_ID_hash VNET(ng_ID_hash) static struct mtx ng_idhash_mtx; @@ -189,7 +189,7 @@ static struct mtx ng_idhash_mtx; } \ } while (0) -static VNET_DEFINE(LIST_HEAD(, ng_node), ng_name_hash[NG_NAME_HASH_SIZE]); +STATIC_VNET_DEFINE(LIST_HEAD(, ng_node), ng_name_hash[NG_NAME_HASH_SIZE]); #define V_ng_name_hash VNET(ng_name_hash) static struct mtx ng_namehash_mtx; @@ -359,7 +359,7 @@ ng_alloc_node(void) #define TRAP_ERROR() #endif -static VNET_DEFINE(ng_ID_t, nextID) = 1; +STATIC_VNET_DEFINE(ng_ID_t, nextID) = 1; #define V_nextID VNET(nextID) #ifdef INVARIANTS Modified: head/sys/netgraph/ng_eiface.c ============================================================================== --- head/sys/netgraph/ng_eiface.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netgraph/ng_eiface.c Sun Nov 14 20:38:11 2010 (r215317) @@ -114,7 +114,7 @@ static struct ng_type typestruct = { }; NETGRAPH_INIT(eiface, &typestruct); -static VNET_DEFINE(struct unrhdr *, ng_eiface_unit); +STATIC_VNET_DEFINE(struct unrhdr *, ng_eiface_unit); #define V_ng_eiface_unit VNET(ng_eiface_unit) /************************************************************************ Modified: head/sys/netgraph/ng_iface.c ============================================================================== --- head/sys/netgraph/ng_iface.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netgraph/ng_iface.c Sun Nov 14 20:38:11 2010 (r215317) @@ -210,7 +210,7 @@ static struct ng_type typestruct = { }; NETGRAPH_INIT(iface, &typestruct); -static VNET_DEFINE(struct unrhdr *, ng_iface_unit); +STATIC_VNET_DEFINE(struct unrhdr *, ng_iface_unit); #define V_ng_iface_unit VNET(ng_iface_unit) /************************************************************************ Modified: head/sys/netinet/if_ether.c ============================================================================== --- head/sys/netinet/if_ether.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/if_ether.c Sun Nov 14 20:38:11 2010 (r215317) @@ -81,17 +81,17 @@ SYSCTL_NODE(_net_link_ether, PF_INET, in SYSCTL_NODE(_net_link_ether, PF_ARP, arp, CTLFLAG_RW, 0, ""); /* timer values */ -static VNET_DEFINE(int, arpt_keep) = (20*60); /* once resolved, good for 20 +STATIC_VNET_DEFINE(int, arpt_keep) = (20*60); /* once resolved, good for 20 * minutes */ -static VNET_DEFINE(int, arp_maxtries) = 5; +STATIC_VNET_DEFINE(int, arp_maxtries) = 5; VNET_DEFINE(int, useloopback) = 1; /* use loopback interface for * local traffic */ -static VNET_DEFINE(int, arp_proxyall) = 0; -static VNET_DEFINE(int, arpt_down) = 20; /* keep incomplete entries for +STATIC_VNET_DEFINE(int, arp_proxyall) = 0; +STATIC_VNET_DEFINE(int, arpt_down) = 20; /* keep incomplete entries for * 20 seconds */ VNET_DEFINE(struct arpstat, arpstat); /* ARP statistics, see if_arp.h */ -static VNET_DEFINE(int, arp_maxhold) = 1; +STATIC_VNET_DEFINE(int, arp_maxhold) = 1; #define V_arpt_keep VNET(arpt_keep) #define V_arpt_down VNET(arpt_down) Modified: head/sys/netinet/igmp.c ============================================================================== --- head/sys/netinet/igmp.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/igmp.c Sun Nov 14 20:38:11 2010 (r215317) @@ -206,11 +206,11 @@ MALLOC_DEFINE(M_IGMP, "igmp", "igmp stat * FUTURE: Stop using IFP_TO_IA/INADDR_ANY, and use source address selection * policy to control the address used by IGMP on the link. */ -static VNET_DEFINE(int, interface_timers_running); /* IGMPv3 general +STATIC_VNET_DEFINE(int, interface_timers_running); /* IGMPv3 general * query response */ -static VNET_DEFINE(int, state_change_timers_running); /* IGMPv3 state-change +STATIC_VNET_DEFINE(int, state_change_timers_running); /* IGMPv3 state-change * retransmit */ -static VNET_DEFINE(int, current_state_timers_running); /* IGMPv1/v2 host +STATIC_VNET_DEFINE(int, current_state_timers_running); /* IGMPv1/v2 host * report; IGMPv3 g/sg * query response */ @@ -218,24 +218,24 @@ static VNET_DEFINE(int, current_state_ti #define V_state_change_timers_running VNET(state_change_timers_running) #define V_current_state_timers_running VNET(current_state_timers_running) -static VNET_DEFINE(LIST_HEAD(, igmp_ifinfo), igi_head); -static VNET_DEFINE(struct igmpstat, igmpstat) = { +STATIC_VNET_DEFINE(LIST_HEAD(, igmp_ifinfo), igi_head); +STATIC_VNET_DEFINE(struct igmpstat, igmpstat) = { .igps_version = IGPS_VERSION_3, .igps_len = sizeof(struct igmpstat), }; -static VNET_DEFINE(struct timeval, igmp_gsrdelay) = {10, 0}; +STATIC_VNET_DEFINE(struct timeval, igmp_gsrdelay) = {10, 0}; #define V_igi_head VNET(igi_head) #define V_igmpstat VNET(igmpstat) #define V_igmp_gsrdelay VNET(igmp_gsrdelay) -static VNET_DEFINE(int, igmp_recvifkludge) = 1; -static VNET_DEFINE(int, igmp_sendra) = 1; -static VNET_DEFINE(int, igmp_sendlocal) = 1; -static VNET_DEFINE(int, igmp_v1enable) = 1; -static VNET_DEFINE(int, igmp_v2enable) = 1; -static VNET_DEFINE(int, igmp_legacysupp); -static VNET_DEFINE(int, igmp_default_version) = IGMP_VERSION_3; +STATIC_VNET_DEFINE(int, igmp_recvifkludge) = 1; +STATIC_VNET_DEFINE(int, igmp_sendra) = 1; +STATIC_VNET_DEFINE(int, igmp_sendlocal) = 1; +STATIC_VNET_DEFINE(int, igmp_v1enable) = 1; +STATIC_VNET_DEFINE(int, igmp_v2enable) = 1; +STATIC_VNET_DEFINE(int, igmp_legacysupp); +STATIC_VNET_DEFINE(int, igmp_default_version) = IGMP_VERSION_3; #define V_igmp_recvifkludge VNET(igmp_recvifkludge) #define V_igmp_sendra VNET(igmp_sendra) Modified: head/sys/netinet/in.c ============================================================================== --- head/sys/netinet/in.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/in.c Sun Nov 14 20:38:11 2010 (r215317) @@ -76,12 +76,12 @@ static int in_ifinit(struct ifnet *, struct in_ifaddr *, struct sockaddr_in *, int); static void in_purgemaddrs(struct ifnet *); -static VNET_DEFINE(int, subnetsarelocal); +STATIC_VNET_DEFINE(int, subnetsarelocal); #define V_subnetsarelocal VNET(subnetsarelocal) SYSCTL_VNET_INT(_net_inet_ip, OID_AUTO, subnets_are_local, CTLFLAG_RW, &VNET_NAME(subnetsarelocal), 0, "Treat all subnets as directly connected"); -static VNET_DEFINE(int, sameprefixcarponly); +STATIC_VNET_DEFINE(int, sameprefixcarponly); #define V_sameprefixcarponly VNET(sameprefixcarponly) SYSCTL_VNET_INT(_net_inet_ip, OID_AUTO, same_prefix_carp_only, CTLFLAG_RW, &VNET_NAME(sameprefixcarponly), 0, Modified: head/sys/netinet/in_pcb.c ============================================================================== --- head/sys/netinet/in_pcb.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/in_pcb.c Sun Nov 14 20:38:11 2010 (r215317) @@ -108,7 +108,7 @@ VNET_DEFINE(int, ipport_randomcps) = 10; VNET_DEFINE(int, ipport_randomtime) = 45; /* user controlled via sysctl */ VNET_DEFINE(int, ipport_stoprandom); /* toggled by ipport_tick */ VNET_DEFINE(int, ipport_tcpallocs); -static VNET_DEFINE(int, ipport_tcplastcount); +STATIC_VNET_DEFINE(int, ipport_tcplastcount); #define V_ipport_tcplastcount VNET(ipport_tcplastcount) Modified: head/sys/netinet/in_rmx.c ============================================================================== --- head/sys/netinet/in_rmx.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/in_rmx.c Sun Nov 14 20:38:11 2010 (r215317) @@ -132,21 +132,21 @@ in_matroute(void *v_arg, struct radix_no return rn; } -static VNET_DEFINE(int, rtq_reallyold) = 60*60; /* one hour is "really old" */ +STATIC_VNET_DEFINE(int, rtq_reallyold) = 60*60; /* one hour is "really old" */ #define V_rtq_reallyold VNET(rtq_reallyold) SYSCTL_VNET_INT(_net_inet_ip, IPCTL_RTEXPIRE, rtexpire, CTLFLAG_RW, &VNET_NAME(rtq_reallyold), 0, "Default expiration time on dynamically learned routes"); /* never automatically crank down to less */ -static VNET_DEFINE(int, rtq_minreallyold) = 10; +STATIC_VNET_DEFINE(int, rtq_minreallyold) = 10; #define V_rtq_minreallyold VNET(rtq_minreallyold) SYSCTL_VNET_INT(_net_inet_ip, IPCTL_RTMINEXPIRE, rtminexpire, CTLFLAG_RW, &VNET_NAME(rtq_minreallyold), 0, "Minimum time to attempt to hold onto dynamically learned routes"); /* 128 cached routes is "too many" */ -static VNET_DEFINE(int, rtq_toomany) = 128; +STATIC_VNET_DEFINE(int, rtq_toomany) = 128; #define V_rtq_toomany VNET(rtq_toomany) SYSCTL_VNET_INT(_net_inet_ip, IPCTL_RTMAXCACHE, rtmaxcache, CTLFLAG_RW, &VNET_NAME(rtq_toomany), 0, @@ -240,8 +240,8 @@ in_rtqkill(struct radix_node *rn, void * } #define RTQ_TIMEOUT 60*10 /* run no less than once every ten minutes */ -static VNET_DEFINE(int, rtq_timeout) = RTQ_TIMEOUT; -static VNET_DEFINE(struct callout, rtq_timer); +STATIC_VNET_DEFINE(int, rtq_timeout) = RTQ_TIMEOUT; +STATIC_VNET_DEFINE(struct callout, rtq_timer); #define V_rtq_timeout VNET(rtq_timeout) #define V_rtq_timer VNET(rtq_timer) Modified: head/sys/netinet/ip_divert.c ============================================================================== --- head/sys/netinet/ip_divert.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/ip_divert.c Sun Nov 14 20:38:11 2010 (r215317) @@ -105,8 +105,8 @@ __FBSDID("$FreeBSD$"); */ /* Internal variables. */ -static VNET_DEFINE(struct inpcbhead, divcb); -static VNET_DEFINE(struct inpcbinfo, divcbinfo); +STATIC_VNET_DEFINE(struct inpcbhead, divcb); +STATIC_VNET_DEFINE(struct inpcbinfo, divcbinfo); #define V_divcb VNET(divcb) #define V_divcbinfo VNET(divcbinfo) Modified: head/sys/netinet/ip_fastfwd.c ============================================================================== --- head/sys/netinet/ip_fastfwd.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/ip_fastfwd.c Sun Nov 14 20:38:11 2010 (r215317) @@ -106,7 +106,7 @@ __FBSDID("$FreeBSD$"); #include -static VNET_DEFINE(int, ipfastforward_active); +STATIC_VNET_DEFINE(int, ipfastforward_active); #define V_ipfastforward_active VNET(ipfastforward_active) SYSCTL_VNET_INT(_net_inet_ip, OID_AUTO, fastforwarding, CTLFLAG_RW, Modified: head/sys/netinet/ip_icmp.c ============================================================================== --- head/sys/netinet/ip_icmp.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/ip_icmp.c Sun Nov 14 20:38:11 2010 (r215317) @@ -80,55 +80,55 @@ VNET_DEFINE(struct icmpstat, icmpstat); SYSCTL_VNET_STRUCT(_net_inet_icmp, ICMPCTL_STATS, stats, CTLFLAG_RW, &VNET_NAME(icmpstat), icmpstat, ""); -static VNET_DEFINE(int, icmpmaskrepl) = 0; +STATIC_VNET_DEFINE(int, icmpmaskrepl) = 0; #define V_icmpmaskrepl VNET(icmpmaskrepl) SYSCTL_VNET_INT(_net_inet_icmp, ICMPCTL_MASKREPL, maskrepl, CTLFLAG_RW, &VNET_NAME(icmpmaskrepl), 0, "Reply to ICMP Address Mask Request packets."); -static VNET_DEFINE(u_int, icmpmaskfake) = 0; +STATIC_VNET_DEFINE(u_int, icmpmaskfake) = 0; #define V_icmpmaskfake VNET(icmpmaskfake) SYSCTL_VNET_UINT(_net_inet_icmp, OID_AUTO, maskfake, CTLFLAG_RW, &VNET_NAME(icmpmaskfake), 0, "Fake reply to ICMP Address Mask Request packets."); -static VNET_DEFINE(int, drop_redirect) = 0; +STATIC_VNET_DEFINE(int, drop_redirect) = 0; #define V_drop_redirect VNET(drop_redirect) SYSCTL_VNET_INT(_net_inet_icmp, OID_AUTO, drop_redirect, CTLFLAG_RW, &VNET_NAME(drop_redirect), 0, "Ignore ICMP redirects"); -static VNET_DEFINE(int, log_redirect) = 0; +STATIC_VNET_DEFINE(int, log_redirect) = 0; #define V_log_redirect VNET(log_redirect) SYSCTL_VNET_INT(_net_inet_icmp, OID_AUTO, log_redirect, CTLFLAG_RW, &VNET_NAME(log_redirect), 0, "Log ICMP redirects to the console"); -static VNET_DEFINE(int, icmplim) = 200; +STATIC_VNET_DEFINE(int, icmplim) = 200; #define V_icmplim VNET(icmplim) SYSCTL_VNET_INT(_net_inet_icmp, ICMPCTL_ICMPLIM, icmplim, CTLFLAG_RW, &VNET_NAME(icmplim), 0, "Maximum number of ICMP responses per second"); -static VNET_DEFINE(int, icmplim_output) = 1; +STATIC_VNET_DEFINE(int, icmplim_output) = 1; #define V_icmplim_output VNET(icmplim_output) SYSCTL_VNET_INT(_net_inet_icmp, OID_AUTO, icmplim_output, CTLFLAG_RW, &VNET_NAME(icmplim_output), 0, "Enable rate limiting of ICMP responses"); -static VNET_DEFINE(char, reply_src[IFNAMSIZ]); +STATIC_VNET_DEFINE(char, reply_src[IFNAMSIZ]); #define V_reply_src VNET(reply_src) SYSCTL_VNET_STRING(_net_inet_icmp, OID_AUTO, reply_src, CTLFLAG_RW, &VNET_NAME(reply_src), IFNAMSIZ, "icmp reply source for non-local packets."); -static VNET_DEFINE(int, icmp_rfi) = 0; +STATIC_VNET_DEFINE(int, icmp_rfi) = 0; #define V_icmp_rfi VNET(icmp_rfi) SYSCTL_VNET_INT(_net_inet_icmp, OID_AUTO, reply_from_interface, CTLFLAG_RW, &VNET_NAME(icmp_rfi), 0, "ICMP reply from incoming interface for non-local packets"); -static VNET_DEFINE(int, icmp_quotelen) = 8; +STATIC_VNET_DEFINE(int, icmp_quotelen) = 8; #define V_icmp_quotelen VNET(icmp_quotelen) SYSCTL_VNET_INT(_net_inet_icmp, OID_AUTO, quotelen, CTLFLAG_RW, &VNET_NAME(icmp_quotelen), 0, @@ -137,7 +137,7 @@ SYSCTL_VNET_INT(_net_inet_icmp, OID_AUTO /* * ICMP broadcast echo sysctl */ -static VNET_DEFINE(int, icmpbmcastecho) = 0; +STATIC_VNET_DEFINE(int, icmpbmcastecho) = 0; #define V_icmpbmcastecho VNET(icmpbmcastecho) SYSCTL_VNET_INT(_net_inet_icmp, OID_AUTO, bmcastecho, CTLFLAG_RW, &VNET_NAME(icmpbmcastecho), 0, Modified: head/sys/netinet/ip_input.c ============================================================================== --- head/sys/netinet/ip_input.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/ip_input.c Sun Nov 14 20:38:11 2010 (r215317) @@ -96,7 +96,7 @@ SYSCTL_VNET_INT(_net_inet_ip, IPCTL_FORW &VNET_NAME(ipforwarding), 0, "Enable IP forwarding between interfaces"); -static VNET_DEFINE(int, ipsendredirects) = 1; /* XXX */ +STATIC_VNET_DEFINE(int, ipsendredirects) = 1; /* XXX */ #define V_ipsendredirects VNET(ipsendredirects) SYSCTL_VNET_INT(_net_inet_ip, IPCTL_SENDREDIRECTS, redirect, CTLFLAG_RW, &VNET_NAME(ipsendredirects), 0, @@ -107,13 +107,13 @@ SYSCTL_VNET_INT(_net_inet_ip, IPCTL_DEFT &VNET_NAME(ip_defttl), 0, "Maximum TTL on IP packets"); -static VNET_DEFINE(int, ip_keepfaith); +STATIC_VNET_DEFINE(int, ip_keepfaith); #define V_ip_keepfaith VNET(ip_keepfaith) SYSCTL_VNET_INT(_net_inet_ip, IPCTL_KEEPFAITH, keepfaith, CTLFLAG_RW, &VNET_NAME(ip_keepfaith), 0, "Enable packet capture for FAITH IPv4->IPv6 translater daemon"); -static VNET_DEFINE(int, ip_sendsourcequench); +STATIC_VNET_DEFINE(int, ip_sendsourcequench); #define V_ip_sendsourcequench VNET(ip_sendsourcequench) SYSCTL_VNET_INT(_net_inet_ip, OID_AUTO, sendsourcequench, CTLFLAG_RW, &VNET_NAME(ip_sendsourcequench), 0, @@ -137,7 +137,7 @@ SYSCTL_VNET_INT(_net_inet_ip, OID_AUTO, * to the loopback interface instead of the interface where the * packets for those addresses are received. */ -static VNET_DEFINE(int, ip_checkinterface); +STATIC_VNET_DEFINE(int, ip_checkinterface); #define V_ip_checkinterface VNET(ip_checkinterface) SYSCTL_VNET_INT(_net_inet_ip, OID_AUTO, check_interface, CTLFLAG_RW, &VNET_NAME(ip_checkinterface), 0, @@ -164,8 +164,8 @@ SYSCTL_VNET_STRUCT(_net_inet_ip, IPCTL_S &VNET_NAME(ipstat), ipstat, "IP statistics (struct ipstat, netinet/ip_var.h)"); -static VNET_DEFINE(uma_zone_t, ipq_zone); -static VNET_DEFINE(TAILQ_HEAD(ipqhead, ipq), ipq[IPREASS_NHASH]); +STATIC_VNET_DEFINE(uma_zone_t, ipq_zone); +STATIC_VNET_DEFINE(TAILQ_HEAD(ipqhead, ipq), ipq[IPREASS_NHASH]); static struct mtx ipqlock; #define V_ipq_zone VNET(ipq_zone) @@ -180,15 +180,15 @@ static void maxnipq_update(void); static void ipq_zone_change(void *); static void ip_drain_locked(void); -static VNET_DEFINE(int, maxnipq); /* Administrative limit on # reass queues. */ -static VNET_DEFINE(int, nipq); /* Total # of reass queues */ +STATIC_VNET_DEFINE(int, maxnipq); /* Administrative limit on # reass queues. */ +STATIC_VNET_DEFINE(int, nipq); /* Total # of reass queues */ #define V_maxnipq VNET(maxnipq) #define V_nipq VNET(nipq) SYSCTL_VNET_INT(_net_inet_ip, OID_AUTO, fragpackets, CTLFLAG_RD, &VNET_NAME(nipq), 0, "Current number of IPv4 fragment reassembly queue entries"); -static VNET_DEFINE(int, maxfragsperpacket); +STATIC_VNET_DEFINE(int, maxfragsperpacket); #define V_maxfragsperpacket VNET(maxfragsperpacket) SYSCTL_VNET_INT(_net_inet_ip, OID_AUTO, maxfragsperpacket, CTLFLAG_RW, &VNET_NAME(maxfragsperpacket), 0, @@ -209,7 +209,7 @@ SYSCTL_VNET_INT(_net_inet_ip, OID_AUTO, #endif #ifdef FLOWTABLE -static VNET_DEFINE(int, ip_output_flowtable_size) = 2048; +STATIC_VNET_DEFINE(int, ip_output_flowtable_size) = 2048; VNET_DEFINE(struct flowtable *, ip_ft); #define V_ip_output_flowtable_size VNET(ip_output_flowtable_size) @@ -1719,7 +1719,7 @@ makedummy: * locking. This code remains in ip_input.c as ip_mroute.c is optionally * compiled. */ -static VNET_DEFINE(int, ip_rsvp_on); +STATIC_VNET_DEFINE(int, ip_rsvp_on); VNET_DEFINE(struct socket *, ip_rsvpd); #define V_ip_rsvp_on VNET(ip_rsvp_on) Modified: head/sys/netinet/ip_ipsec.c ============================================================================== --- head/sys/netinet/ip_ipsec.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/ip_ipsec.c Sun Nov 14 20:38:11 2010 (r215317) @@ -72,9 +72,9 @@ extern struct protosw inetsw[]; #ifdef IPSEC #ifdef IPSEC_FILTERTUNNEL -static VNET_DEFINE(int, ip4_ipsec_filtertunnel) = 1; +STATIC_VNET_DEFINE(int, ip4_ipsec_filtertunnel) = 1; #else -static VNET_DEFINE(int, ip4_ipsec_filtertunnel) = 0; +STATIC_VNET_DEFINE(int, ip4_ipsec_filtertunnel) = 0; #endif #define V_ip4_ipsec_filtertunnel VNET(ip4_ipsec_filtertunnel) Modified: head/sys/netinet/ip_mroute.c ============================================================================== --- head/sys/netinet/ip_mroute.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/ip_mroute.c Sun Nov 14 20:38:11 2010 (r215317) @@ -121,7 +121,7 @@ __FBSDID("$FreeBSD$"); #define VIFI_INVALID ((vifi_t) -1) #define M_HASCL(m) ((m)->m_flags & M_EXT) -static VNET_DEFINE(uint32_t, last_tv_sec); /* last time we processed this */ +STATIC_VNET_DEFINE(uint32_t, last_tv_sec); /* last time we processed this */ #define V_last_tv_sec VNET(last_tv_sec) static MALLOC_DEFINE(M_MRTABLE, "mroutetbl", "multicast forwarding cache"); @@ -145,14 +145,14 @@ static struct mtx mrouter_mtx; static int ip_mrouter_cnt; /* # of vnets with active mrouters */ static int ip_mrouter_unloading; /* Allow no more V_ip_mrouter sockets */ -static VNET_DEFINE(struct mrtstat, mrtstat); +STATIC_VNET_DEFINE(struct mrtstat, mrtstat); #define V_mrtstat VNET(mrtstat) SYSCTL_VNET_STRUCT(_net_inet_ip, OID_AUTO, mrtstat, CTLFLAG_RW, &VNET_NAME(mrtstat), mrtstat, "IPv4 Multicast Forwarding Statistics (struct mrtstat, " "netinet/ip_mroute.h)"); -static VNET_DEFINE(u_long, mfchash); +STATIC_VNET_DEFINE(u_long, mfchash); #define V_mfchash VNET(mfchash) #define MFCHASH(a, g) \ ((((a).s_addr >> 20) ^ ((a).s_addr >> 10) ^ (a).s_addr ^ \ @@ -160,9 +160,9 @@ static VNET_DEFINE(u_long, mfchash); #define MFCHASHSIZE 256 static u_long mfchashsize; /* Hash size */ -static VNET_DEFINE(u_char *, nexpire); /* 0..mfchashsize-1 */ +STATIC_VNET_DEFINE(u_char *, nexpire); /* 0..mfchashsize-1 */ #define V_nexpire VNET(nexpire) -static VNET_DEFINE(LIST_HEAD(mfchashhdr, mfc)*, mfchashtbl); +STATIC_VNET_DEFINE(LIST_HEAD(mfchashhdr, mfc)*, mfchashtbl); #define V_mfchashtbl VNET(mfchashtbl) static struct mtx mfc_mtx; @@ -173,9 +173,9 @@ static struct mtx mfc_mtx; mtx_init(&mfc_mtx, "IPv4 multicast forwarding cache", NULL, MTX_DEF) #define MFC_LOCK_DESTROY() mtx_destroy(&mfc_mtx) -static VNET_DEFINE(vifi_t, numvifs); +STATIC_VNET_DEFINE(vifi_t, numvifs); #define V_numvifs VNET(numvifs) -static VNET_DEFINE(struct vif, viftable[MAXVIFS]); +STATIC_VNET_DEFINE(struct vif, viftable[MAXVIFS]); #define V_viftable VNET(viftable) SYSCTL_VNET_OPAQUE(_net_inet_ip, OID_AUTO, viftable, CTLFLAG_RD, &VNET_NAME(viftable), sizeof(V_viftable), "S,vif[MAXVIFS]", @@ -191,7 +191,7 @@ static struct mtx vif_mtx; static eventhandler_tag if_detach_event_tag = NULL; -static VNET_DEFINE(struct callout, expire_upcalls_ch); +STATIC_VNET_DEFINE(struct callout, expire_upcalls_ch); #define V_expire_upcalls_ch VNET(expire_upcalls_ch) #define EXPIRE_TIMEOUT (hz / 4) /* 4x / second */ @@ -206,9 +206,9 @@ static MALLOC_DEFINE(M_BWMETER, "bwmeter * expiration time. Periodically, the entries are analysed and processed. */ #define BW_METER_BUCKETS 1024 -static VNET_DEFINE(struct bw_meter*, bw_meter_timers[BW_METER_BUCKETS]); +STATIC_VNET_DEFINE(struct bw_meter*, bw_meter_timers[BW_METER_BUCKETS]); #define V_bw_meter_timers VNET(bw_meter_timers) -static VNET_DEFINE(struct callout, bw_meter_ch); +STATIC_VNET_DEFINE(struct callout, bw_meter_ch); #define V_bw_meter_ch VNET(bw_meter_ch) #define BW_METER_PERIOD (hz) /* periodical handling of bw meters */ @@ -216,16 +216,16 @@ static VNET_DEFINE(struct callout, bw_me * Pending upcalls are stored in a vector which is flushed when * full, or periodically */ -static VNET_DEFINE(struct bw_upcall, bw_upcalls[BW_UPCALLS_MAX]); +STATIC_VNET_DEFINE(struct bw_upcall, bw_upcalls[BW_UPCALLS_MAX]); #define V_bw_upcalls VNET(bw_upcalls) -static VNET_DEFINE(u_int, bw_upcalls_n); /* # of pending upcalls */ +STATIC_VNET_DEFINE(u_int, bw_upcalls_n); /* # of pending upcalls */ #define V_bw_upcalls_n VNET(bw_upcalls_n) -static VNET_DEFINE(struct callout, bw_upcalls_ch); +STATIC_VNET_DEFINE(struct callout, bw_upcalls_ch); #define V_bw_upcalls_ch VNET(bw_upcalls_ch) #define BW_UPCALLS_PERIOD (hz) /* periodical flush of bw upcalls */ -static VNET_DEFINE(struct pimstat, pimstat); +STATIC_VNET_DEFINE(struct pimstat, pimstat); #define V_pimstat VNET(pimstat) SYSCTL_NODE(_net_inet, IPPROTO_PIM, pim, CTLFLAG_RW, 0, "PIM"); @@ -296,9 +296,9 @@ static struct pim_encap_pimhdr pim_encap 0 /* flags */ }; -static VNET_DEFINE(vifi_t, reg_vif_num) = VIFI_INVALID; +STATIC_VNET_DEFINE(vifi_t, reg_vif_num) = VIFI_INVALID; #define V_reg_vif_num VNET(reg_vif_num) -static VNET_DEFINE(struct ifnet, multicast_register_if); +STATIC_VNET_DEFINE(struct ifnet, multicast_register_if); #define V_multicast_register_if VNET(multicast_register_if) /* @@ -367,9 +367,9 @@ static const uint32_t mrt_api_support = MRT_MFC_FLAGS_BORDER_VIF | MRT_MFC_RP | MRT_MFC_BW_UPCALL); -static VNET_DEFINE(uint32_t, mrt_api_config); +STATIC_VNET_DEFINE(uint32_t, mrt_api_config); #define V_mrt_api_config VNET(mrt_api_config) -static VNET_DEFINE(int, pim_assert_enabled); +STATIC_VNET_DEFINE(int, pim_assert_enabled); #define V_pim_assert_enabled VNET(pim_assert_enabled) static struct timeval pim_assert_interval = { 3, 0 }; /* Rate limit */ Modified: head/sys/netinet/ipfw/ip_fw2.c ============================================================================== --- head/sys/netinet/ipfw/ip_fw2.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/ipfw/ip_fw2.c Sun Nov 14 20:38:11 2010 (r215317) @@ -100,10 +100,10 @@ __FBSDID("$FreeBSD$"); */ /* ipfw_vnet_ready controls when we are open for business */ -static VNET_DEFINE(int, ipfw_vnet_ready) = 0; +STATIC_VNET_DEFINE(int, ipfw_vnet_ready) = 0; #define V_ipfw_vnet_ready VNET(ipfw_vnet_ready) -static VNET_DEFINE(int, fw_deny_unknown_exthdrs); +STATIC_VNET_DEFINE(int, fw_deny_unknown_exthdrs); #define V_fw_deny_unknown_exthdrs VNET(fw_deny_unknown_exthdrs) #ifdef IPFIREWALL_DEFAULT_TO_ACCEPT Modified: head/sys/netinet/ipfw/ip_fw_dynamic.c ============================================================================== --- head/sys/netinet/ipfw/ip_fw_dynamic.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/ipfw/ip_fw_dynamic.c Sun Nov 14 20:38:11 2010 (r215317) @@ -118,10 +118,10 @@ __FBSDID("$FreeBSD$"); /* * Static variables followed by global ones */ -static VNET_DEFINE(ipfw_dyn_rule **, ipfw_dyn_v); -static VNET_DEFINE(u_int32_t, dyn_buckets); -static VNET_DEFINE(u_int32_t, curr_dyn_buckets); -static VNET_DEFINE(struct callout, ipfw_timeout); +STATIC_VNET_DEFINE(ipfw_dyn_rule **, ipfw_dyn_v); +STATIC_VNET_DEFINE(u_int32_t, dyn_buckets); +STATIC_VNET_DEFINE(u_int32_t, curr_dyn_buckets); +STATIC_VNET_DEFINE(struct callout, ipfw_timeout); #define V_ipfw_dyn_v VNET(ipfw_dyn_v) #define V_dyn_buckets VNET(dyn_buckets) #define V_curr_dyn_buckets VNET(curr_dyn_buckets) @@ -150,12 +150,12 @@ ipfw_dyn_unlock(void) /* * Timeouts for various events in handing dynamic rules. */ -static VNET_DEFINE(u_int32_t, dyn_ack_lifetime); -static VNET_DEFINE(u_int32_t, dyn_syn_lifetime); -static VNET_DEFINE(u_int32_t, dyn_fin_lifetime); -static VNET_DEFINE(u_int32_t, dyn_rst_lifetime); -static VNET_DEFINE(u_int32_t, dyn_udp_lifetime); -static VNET_DEFINE(u_int32_t, dyn_short_lifetime); +STATIC_VNET_DEFINE(u_int32_t, dyn_ack_lifetime); +STATIC_VNET_DEFINE(u_int32_t, dyn_syn_lifetime); +STATIC_VNET_DEFINE(u_int32_t, dyn_fin_lifetime); +STATIC_VNET_DEFINE(u_int32_t, dyn_rst_lifetime); +STATIC_VNET_DEFINE(u_int32_t, dyn_udp_lifetime); +STATIC_VNET_DEFINE(u_int32_t, dyn_short_lifetime); #define V_dyn_ack_lifetime VNET(dyn_ack_lifetime) #define V_dyn_syn_lifetime VNET(dyn_syn_lifetime) @@ -172,16 +172,16 @@ static VNET_DEFINE(u_int32_t, dyn_short_ * than dyn_keepalive_period. */ -static VNET_DEFINE(u_int32_t, dyn_keepalive_interval); -static VNET_DEFINE(u_int32_t, dyn_keepalive_period); -static VNET_DEFINE(u_int32_t, dyn_keepalive); +STATIC_VNET_DEFINE(u_int32_t, dyn_keepalive_interval); +STATIC_VNET_DEFINE(u_int32_t, dyn_keepalive_period); +STATIC_VNET_DEFINE(u_int32_t, dyn_keepalive); #define V_dyn_keepalive_interval VNET(dyn_keepalive_interval) #define V_dyn_keepalive_period VNET(dyn_keepalive_period) #define V_dyn_keepalive VNET(dyn_keepalive) -static VNET_DEFINE(u_int32_t, dyn_count); /* # of dynamic rules */ -static VNET_DEFINE(u_int32_t, dyn_max); /* max # of dynamic rules */ +STATIC_VNET_DEFINE(u_int32_t, dyn_count); /* # of dynamic rules */ +STATIC_VNET_DEFINE(u_int32_t, dyn_max); /* max # of dynamic rules */ #define V_dyn_count VNET(dyn_count) #define V_dyn_max VNET(dyn_max) Modified: head/sys/netinet/ipfw/ip_fw_nat.c ============================================================================== --- head/sys/netinet/ipfw/ip_fw_nat.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/ipfw/ip_fw_nat.c Sun Nov 14 20:38:11 2010 (r215317) @@ -52,7 +52,7 @@ __FBSDID("$FreeBSD$"); #include /* XXX for in_cksum */ -static VNET_DEFINE(eventhandler_tag, ifaddr_event_tag); +STATIC_VNET_DEFINE(eventhandler_tag, ifaddr_event_tag); #define V_ifaddr_event_tag VNET(ifaddr_event_tag) static void Modified: head/sys/netinet/ipfw/ip_fw_pfil.c ============================================================================== --- head/sys/netinet/ipfw/ip_fw_pfil.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/ipfw/ip_fw_pfil.c Sun Nov 14 20:38:11 2010 (r215317) @@ -63,11 +63,11 @@ __FBSDID("$FreeBSD$"); #include -static VNET_DEFINE(int, fw_enable) = 1; +STATIC_VNET_DEFINE(int, fw_enable) = 1; #define V_fw_enable VNET(fw_enable) #ifdef INET6 -static VNET_DEFINE(int, fw6_enable) = 1; +STATIC_VNET_DEFINE(int, fw6_enable) = 1; #define V_fw6_enable VNET(fw6_enable) #endif Modified: head/sys/netinet/siftr.c ============================================================================== --- head/sys/netinet/siftr.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/siftr.c Sun Nov 14 20:38:11 2010 (r215317) @@ -260,7 +260,7 @@ struct siftr_stats uint32_t nskip_out_dejavu; }; -static DPCPU_DEFINE(struct siftr_stats, ss); +STATIC_DPCPU_DEFINE(struct siftr_stats, ss); static volatile unsigned int siftr_exit_pkt_manager_thread = 0; static unsigned int siftr_enabled = 0; Modified: head/sys/netinet/tcp_hostcache.c ============================================================================== --- head/sys/netinet/tcp_hostcache.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/tcp_hostcache.c Sun Nov 14 20:38:11 2010 (r215317) @@ -106,10 +106,10 @@ __FBSDID("$FreeBSD$"); #define TCP_HOSTCACHE_EXPIRE 60*60 /* one hour */ #define TCP_HOSTCACHE_PRUNE 5*60 /* every 5 minutes */ -static VNET_DEFINE(struct tcp_hostcache, tcp_hostcache); +STATIC_VNET_DEFINE(struct tcp_hostcache, tcp_hostcache); #define V_tcp_hostcache VNET(tcp_hostcache) -static VNET_DEFINE(struct callout, tcp_hc_callout); +STATIC_VNET_DEFINE(struct callout, tcp_hc_callout); #define V_tcp_hc_callout VNET(tcp_hc_callout) static struct hc_metrics *tcp_hc_lookup(struct in_conninfo *); Modified: head/sys/netinet/tcp_reass.c ============================================================================== --- head/sys/netinet/tcp_reass.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/tcp_reass.c Sun Nov 14 20:38:11 2010 (r215317) @@ -80,25 +80,25 @@ static int tcp_reass_sysctl_qsize(SYSCTL SYSCTL_NODE(_net_inet_tcp, OID_AUTO, reass, CTLFLAG_RW, 0, "TCP Segment Reassembly Queue"); -static VNET_DEFINE(int, tcp_reass_maxseg) = 0; +STATIC_VNET_DEFINE(int, tcp_reass_maxseg) = 0; #define V_tcp_reass_maxseg VNET(tcp_reass_maxseg) SYSCTL_VNET_PROC(_net_inet_tcp_reass, OID_AUTO, maxsegments, CTLFLAG_RDTUN, &VNET_NAME(tcp_reass_maxseg), 0, &tcp_reass_sysctl_maxseg, "I", "Global maximum number of TCP Segments in Reassembly Queue"); -static VNET_DEFINE(int, tcp_reass_qsize) = 0; +STATIC_VNET_DEFINE(int, tcp_reass_qsize) = 0; #define V_tcp_reass_qsize VNET(tcp_reass_qsize) SYSCTL_VNET_PROC(_net_inet_tcp_reass, OID_AUTO, cursegments, CTLFLAG_RD, &VNET_NAME(tcp_reass_qsize), 0, &tcp_reass_sysctl_qsize, "I", "Global number of TCP Segments currently in Reassembly Queue"); -static VNET_DEFINE(int, tcp_reass_overflows) = 0; +STATIC_VNET_DEFINE(int, tcp_reass_overflows) = 0; #define V_tcp_reass_overflows VNET(tcp_reass_overflows) SYSCTL_VNET_INT(_net_inet_tcp_reass, OID_AUTO, overflows, CTLFLAG_RD, &VNET_NAME(tcp_reass_overflows), 0, "Global number of TCP Segment Reassembly Queue Overflows"); -static VNET_DEFINE(uma_zone_t, tcp_reass_zone); +STATIC_VNET_DEFINE(uma_zone_t, tcp_reass_zone); #define V_tcp_reass_zone VNET(tcp_reass_zone) /* Initialize TCP reassembly queue */ Modified: head/sys/netinet/tcp_subr.c ============================================================================== --- head/sys/netinet/tcp_subr.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/tcp_subr.c Sun Nov 14 20:38:11 2010 (r215317) @@ -193,13 +193,13 @@ SYSCTL_INT(_net_inet_tcp, OID_AUTO, do_t SYSCTL_VNET_INT(_net_inet_tcp, OID_AUTO, pcbcount, CTLFLAG_RD, &VNET_NAME(tcbinfo.ipi_count), 0, "Number of active PCBs"); -static VNET_DEFINE(int, icmp_may_rst) = 1; +STATIC_VNET_DEFINE(int, icmp_may_rst) = 1; #define V_icmp_may_rst VNET(icmp_may_rst) SYSCTL_VNET_INT(_net_inet_tcp, OID_AUTO, icmp_may_rst, CTLFLAG_RW, &VNET_NAME(icmp_may_rst), 0, "Certain ICMP unreachable messages may abort connections in SYN_SENT"); -static VNET_DEFINE(int, tcp_isn_reseed_interval) = 0; +STATIC_VNET_DEFINE(int, tcp_isn_reseed_interval) = 0; #define V_tcp_isn_reseed_interval VNET(tcp_isn_reseed_interval) SYSCTL_VNET_INT(_net_inet_tcp, OID_AUTO, isn_reseed_interval, CTLFLAG_RW, &VNET_NAME(tcp_isn_reseed_interval), 0, @@ -241,7 +241,7 @@ struct tcpcb_mem { struct cc_var ccv; }; -static VNET_DEFINE(uma_zone_t, tcpcb_zone); +STATIC_VNET_DEFINE(uma_zone_t, tcpcb_zone); #define V_tcpcb_zone VNET(tcpcb_zone) MALLOC_DEFINE(M_TCPLOG, "tcplog", "TCP address and flags print buffers"); @@ -1453,10 +1453,10 @@ tcp6_ctlinput(int cmd, struct sockaddr * #define ISN_STATIC_INCREMENT 4096 #define ISN_RANDOM_INCREMENT (4096 - 1) -static VNET_DEFINE(u_char, isn_secret[32]); -static VNET_DEFINE(int, isn_last_reseed); -static VNET_DEFINE(u_int32_t, isn_offset); -static VNET_DEFINE(u_int32_t, isn_offset_old); +STATIC_VNET_DEFINE(u_char, isn_secret[32]); +STATIC_VNET_DEFINE(int, isn_last_reseed); +STATIC_VNET_DEFINE(u_int32_t, isn_offset); +STATIC_VNET_DEFINE(u_int32_t, isn_offset_old); #define V_isn_secret VNET(isn_secret) #define V_isn_last_reseed VNET(isn_last_reseed) Modified: head/sys/netinet/tcp_syncache.c ============================================================================== --- head/sys/netinet/tcp_syncache.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/tcp_syncache.c Sun Nov 14 20:38:11 2010 (r215317) @@ -97,13 +97,13 @@ __FBSDID("$FreeBSD$"); #include -static VNET_DEFINE(int, tcp_syncookies) = 1; +STATIC_VNET_DEFINE(int, tcp_syncookies) = 1; #define V_tcp_syncookies VNET(tcp_syncookies) SYSCTL_VNET_INT(_net_inet_tcp, OID_AUTO, syncookies, CTLFLAG_RW, &VNET_NAME(tcp_syncookies), 0, "Use TCP SYN cookies if the syncache overflows"); -static VNET_DEFINE(int, tcp_syncookiesonly) = 0; +STATIC_VNET_DEFINE(int, tcp_syncookiesonly) = 0; #define V_tcp_syncookiesonly VNET(tcp_syncookiesonly) SYSCTL_VNET_INT(_net_inet_tcp, OID_AUTO, syncookies_only, CTLFLAG_RW, &VNET_NAME(tcp_syncookiesonly), 0, @@ -143,7 +143,7 @@ static struct syncache #define TCP_SYNCACHE_HASHSIZE 512 #define TCP_SYNCACHE_BUCKETLIMIT 30 -static VNET_DEFINE(struct tcp_syncache, tcp_syncache); +STATIC_VNET_DEFINE(struct tcp_syncache, tcp_syncache); #define V_tcp_syncache VNET(tcp_syncache) SYSCTL_NODE(_net_inet_tcp, OID_AUTO, syncache, CTLFLAG_RW, 0, "TCP SYN cache"); Modified: head/sys/netinet/tcp_timewait.c ============================================================================== --- head/sys/netinet/tcp_timewait.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/tcp_timewait.c Sun Nov 14 20:38:11 2010 (r215317) @@ -92,7 +92,7 @@ __FBSDID("$FreeBSD$"); #include -static VNET_DEFINE(uma_zone_t, tcptw_zone); +STATIC_VNET_DEFINE(uma_zone_t, tcptw_zone); #define V_tcptw_zone VNET(tcptw_zone) static int maxtcptw; @@ -102,7 +102,7 @@ static int maxtcptw; * queue pointers in each tcptw structure, are protected using the global * tcbinfo lock, which must be held over queue iteration and modification. */ -static VNET_DEFINE(TAILQ_HEAD(, tcptw), twq_2msl); +STATIC_VNET_DEFINE(TAILQ_HEAD(, tcptw), twq_2msl); #define V_twq_2msl VNET(twq_2msl) static void tcp_tw_2msl_reset(struct tcptw *, int); Modified: head/sys/netinet/udp_usrreq.c ============================================================================== --- head/sys/netinet/udp_usrreq.c Sun Nov 14 20:23:02 2010 (r215316) +++ head/sys/netinet/udp_usrreq.c Sun Nov 14 20:38:11 2010 (r215317) @@ -131,7 +131,7 @@ SYSCTL_ULONG(_net_inet_udp, UDPCTL_RECVS VNET_DEFINE(struct inpcbhead, udb); /* from udp_var.h */ VNET_DEFINE(struct inpcbinfo, udbinfo); -static VNET_DEFINE(uma_zone_t, udpcb_zone); +STATIC_VNET_DEFINE(uma_zone_t, udpcb_zone); *** DIFF OUTPUT TRUNCATED AT 1000 LINES ***