freebsd-nq/sys/netinet
Andrew Thompson febd0759f3 Change the reference counting to count the number of cloned interfaces for each
cloner. This ensures that ifc->ifc_units is not prematurely freed in
if_clone_detach() before the clones are destroyed, resulting in memory modified
after free. This could be triggered with if_vlan.

Assert that all cloners have been destroyed when freeing the memory.

Change all simple cloners to destroy their clones with ifc_simple_destroy() on
module unload so the reference count is properly updated. This also cleans up
the interface destroy routines and allows future optimisation.

Discussed with:	brooks, pjd, -current
Reviewed by:	brooks
2005-10-12 19:52:16 +00:00
..
libalias Use monotonic 'time_uptime' instead of 'time_second' as timebase 2005-09-19 22:31:45 +00:00
accf_data.c
accf_http.c
icmp6.h
icmp_var.h
if_atm.c Add newline to debuging printf. 2005-08-26 15:27:18 +00:00
if_atm.h
if_ether.c When bridging is enabled and an ARP request is recieved on a member interface, 2005-10-04 19:50:02 +00:00
if_ether.h
igmp_var.h
igmp.c
igmp.h
in_cksum.c
in_gif.c
in_gif.h
in_pcb.c
in_pcb.h Implement IP_DONTFRAG IP socket option enabling the Don't Fragment 2005-09-26 20:25:16 +00:00
in_proto.c Match IPv6 and use a static struct pr_usrreqs nousrreqs. 2005-08-10 06:41:04 +00:00
in_rmx.c Use monotonic 'time_uptime' instead of 'time_second' as timebase 2005-09-19 22:54:55 +00:00
in_systm.h
in_var.h
in.c Unlock Giant symmetrically with respect to lock acquire order as that's 2005-10-03 11:34:29 +00:00
in.h Implement IP_DONTFRAG IP socket option enabling the Don't Fragment 2005-09-26 20:25:16 +00:00
ip6.h
ip_carp.c Change the reference counting to count the number of cloned interfaces for each 2005-10-12 19:52:16 +00:00
ip_carp.h
ip_divert.c
ip_divert.h
ip_dummynet.c Remove bridge(4) from the tree. if_bridge(4) is a full functional 2005-09-27 18:10:43 +00:00
ip_dummynet.h Remove bridge(4) from the tree. if_bridge(4) is a full functional 2005-09-27 18:10:43 +00:00
ip_ecn.c
ip_ecn.h
ip_encap.c
ip_encap.h
ip_fastfwd.c Use monotonic 'time_uptime' instead of 'time_second' as timebase 2005-09-19 22:54:55 +00:00
ip_fw2.c Remove bridge(4) from the tree. if_bridge(4) is a full functional 2005-09-27 18:10:43 +00:00
ip_fw_pfil.c
ip_fw.h * Add dynamic sysctl for net.inet6.ip6.fw. 2005-08-13 11:02:34 +00:00
ip_gre.c
ip_gre.h
ip_icmp.c o Fix a logic error when not doing mbuf cluster allocation. 2005-08-22 22:13:41 +00:00
ip_icmp.h
ip_id.c
ip_input.c Use the correct mbuf type for MGET(). 2005-08-30 16:35:27 +00:00
ip_mroute.c Use monotonic 'time_uptime' instead of 'time_second' as timebase 2005-09-19 22:31:45 +00:00
ip_mroute.h
ip_output.c Implement IP_DONTFRAG IP socket option enabling the Don't Fragment 2005-09-26 20:25:16 +00:00
ip_var.h
ip.h
ipprotosw.h
pim_var.h Remove public declarations of variables that were forgotten when they were 2005-08-10 07:10:02 +00:00
pim.h
raw_ip.c o INP_ONESBCAST is inpcb.inp_vflag flag not inp_flags. The confusion 2005-10-12 18:13:25 +00:00
tcp_debug.c
tcp_debug.h
tcp_fsm.h
tcp_hostcache.c
tcp_input.c Remove a KASSERT in the sack path that fails because of a interaction 2005-08-24 02:48:45 +00:00
tcp_output.c
tcp_reass.c Remove a KASSERT in the sack path that fails because of a interaction 2005-08-24 02:48:45 +00:00
tcp_sack.c Remove unnecessary IPSEC includes. 2005-08-23 14:42:40 +00:00
tcp_seq.h
tcp_subr.c Unbreak the net.inet6.tcp6.getcred sysctl. 2005-10-12 09:24:18 +00:00
tcp_syncache.c Do not ignore all other TCP options (eg. timestamp, window scaling) 2005-09-14 15:06:22 +00:00
tcp_timer.c
tcp_timer.h
tcp_timewait.c Unbreak the net.inet6.tcp6.getcred sysctl. 2005-10-12 09:24:18 +00:00
tcp_usrreq.c Remove unnecessary IPSEC includes. 2005-08-23 14:42:40 +00:00
tcp_var.h
tcp.h Fix up the comment for MAX_SACK_BLKS. 2005-08-24 02:47:16 +00:00
tcpip.h
udp_usrreq.c o INP_ONESBCAST is inpcb.inp_vflag flag not inp_flags. The confusion 2005-10-12 18:13:25 +00:00
udp_var.h
udp.h