kernel-ark/net/ipv4/netfilter
Harald Welte 1dfbab5949 [NETFILTER] Fix conntrack event cache deadlock/oops
This patch fixes a number of bugs.  It cannot be reasonably split up in
multiple fixes, since all bugs interact with each other and affect the same
function:

Bug #1:
The event cache code cannot be called while a lock is held.  Therefore, the
call to ip_conntrack_event_cache() within ip_ct_refresh_acct() needs to be
moved outside of the locked section.  This fixes a number of 2.6.14-rcX
oops and deadlock reports.

Bug #2:
We used to call ct_add_counters() for unconfirmed connections without
holding a lock.  Since the add operations are not atomic, we could race
with another CPU.

Bug #3:
ip_ct_refresh_acct() lost REFRESH events in some cases where refresh
(and the corresponding event) are desired, but no accounting shall be
performed.  Both, evenst and accounting implicitly depended on the skb
parameter bein non-null.   We now re-introduce a non-accounting
"ip_ct_refresh()" variant to explicitly state the desired behaviour.

Signed-off-by: Harald Welte <laforge@netfilter.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-09-22 23:46:57 -07:00
..
arp_tables.c
arpt_mangle.c
arptable_filter.c
ip_conntrack_amanda.c [NETFILTER] Fix conntrack event cache deadlock/oops 2005-09-22 23:46:57 -07:00
ip_conntrack_core.c [NETFILTER] Fix conntrack event cache deadlock/oops 2005-09-22 23:46:57 -07:00
ip_conntrack_ftp.c [NETFILTER]: Use correct type for "ports" module parameter 2005-09-13 13:48:00 -07:00
ip_conntrack_helper_pptp.c [NETFILTER] Fix conntrack event cache deadlock/oops 2005-09-22 23:46:57 -07:00
ip_conntrack_irc.c [NETFILTER]: Use correct type for "ports" module parameter 2005-09-13 13:48:00 -07:00
ip_conntrack_netbios_ns.c [NETFILTER] Fix conntrack event cache deadlock/oops 2005-09-22 23:46:57 -07:00
ip_conntrack_netlink.c [NETFILTER]: Rename misnamed function 2005-09-19 15:35:31 -07:00
ip_conntrack_proto_generic.c
ip_conntrack_proto_gre.c [NETFILTER]: Add new PPTP conntrack and NAT helper 2005-09-19 15:33:08 -07:00
ip_conntrack_proto_icmp.c
ip_conntrack_proto_sctp.c
ip_conntrack_proto_tcp.c [NETFILTER]: Missing unlock in TCP connection tracking error path 2005-09-06 15:11:10 -07:00
ip_conntrack_proto_udp.c
ip_conntrack_standalone.c [NETFILTER] Fix conntrack event cache deadlock/oops 2005-09-22 23:46:57 -07:00
ip_conntrack_tftp.c [NETFILTER]: Use correct type for "ports" module parameter 2005-09-13 13:48:00 -07:00
ip_nat_amanda.c
ip_nat_core.c [NETFILTER]: Export ip_nat_port_{nfattr_to_range,range_to_nfattr} 2005-09-19 15:35:57 -07:00
ip_nat_ftp.c
ip_nat_helper_pptp.c [NETFILTER]: Add new PPTP conntrack and NAT helper 2005-09-19 15:33:08 -07:00
ip_nat_helper.c
ip_nat_irc.c
ip_nat_proto_gre.c [NETFILTER]: Add new PPTP conntrack and NAT helper 2005-09-19 15:33:08 -07:00
ip_nat_proto_icmp.c
ip_nat_proto_tcp.c
ip_nat_proto_udp.c
ip_nat_proto_unknown.c
ip_nat_rule.c [NETFILTER]: Handle NAT module load race 2005-09-06 15:09:43 -07:00
ip_nat_snmp_basic.c
ip_nat_standalone.c [NETFILTER]: Handle NAT module load race 2005-09-06 15:09:43 -07:00
ip_nat_tftp.c
ip_queue.c
ip_tables.c
ipt_addrtype.c
ipt_ah.c
ipt_CLASSIFY.c
ipt_CLUSTERIP.c [NETFILTER] CLUSTERIP: use a bitmap to store node responsibility data 2005-09-16 17:00:04 -07:00
ipt_comment.c
ipt_connbytes.c
ipt_connmark.c
ipt_CONNMARK.c
ipt_conntrack.c
ipt_dccp.c
ipt_dscp.c
ipt_DSCP.c
ipt_ecn.c
ipt_ECN.c
ipt_esp.c
ipt_hashlimit.c [NET]: use __read_mostly on kmem_cache_t , DEFINE_SNMP_STAT pointers 2005-08-29 16:11:18 -07:00
ipt_helper.c
ipt_iprange.c
ipt_length.c
ipt_limit.c
ipt_LOG.c
ipt_mac.c
ipt_mark.c
ipt_MARK.c
ipt_MASQUERADE.c [NETFILTER]: Fix DHCP + MASQUERADE problem 2005-09-13 13:49:15 -07:00
ipt_multiport.c
ipt_NETMAP.c
ipt_NFQUEUE.c
ipt_NOTRACK.c
ipt_owner.c [PATCH] files: lock-free fd look-up 2005-09-09 13:57:55 -07:00
ipt_physdev.c
ipt_pkttype.c
ipt_realm.c
ipt_recent.c
ipt_REDIRECT.c [NETFILTER]: Fix rcu race in ipt_REDIRECT 2005-09-13 13:48:58 -07:00
ipt_REJECT.c [XFRM]: Always release dst_entry on error in xfrm_lookup 2005-09-08 15:11:55 -07:00
ipt_SAME.c
ipt_sctp.c
ipt_state.c
ipt_string.c
ipt_tcpmss.c
ipt_TCPMSS.c
ipt_tos.c
ipt_TOS.c
ipt_ttl.c
ipt_TTL.c [NETFILTER]: Add new iptables TTL target 2005-08-29 16:13:22 -07:00
ipt_ULOG.c
iptable_filter.c
iptable_mangle.c
iptable_raw.c
Kconfig [NETFILTER]: Add new PPTP conntrack and NAT helper 2005-09-19 15:33:08 -07:00
Makefile [NETFILTER]: Add new PPTP conntrack and NAT helper 2005-09-19 15:33:08 -07:00