linux/include/net/netns
Eric Dumazet be9f4a44e7 ipv4: tcp: remove per net tcp_sock
tcp_v4_send_reset() and tcp_v4_send_ack() use a single socket
per network namespace.

This leads to bad behavior on multiqueue NICS, because many cpus
contend for the socket lock and once socket lock is acquired, extra
false sharing on various socket fields slow down the operations.

To better resist to attacks, we use a percpu socket. Each cpu can
run without contention, using appropriate memory (local node)

Additional features :

1) We also mirror the queue_mapping of the incoming skb, so that
answers use the same queue if possible.

2) Setting SOCK_USE_WRITE_QUEUE socket flag speedup sock_wfree()

3) We now limit the number of in-flight RST/ACK [1] packets
per cpu, instead of per namespace, and we honor the sysctl_wmem_default
limit dynamically. (Prior to this patch, sysctl_wmem_default value was
copied at boot time, so any further change would not affect tcp_sock
limit)

[1] These packets are only generated when no socket was matched for
the incoming packet.

Reported-by: Bill Sommerfeld <wsommerfeld@google.com>
Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: Tom Herbert <therbert@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2012-07-19 10:35:30 -07:00
..
conntrack.h netfilter: nf_ct_icmp: add namespace support 2012-06-07 14:58:40 +02:00
core.h percpu: add __percpu sparse annotations to net 2010-02-16 23:05:38 -08:00
dccp.h [NETNS][DCCPV6]: Move the dccp_v6_ctl_sk on the struct net. 2008-04-13 22:32:25 -07:00
generic.h BUG: headers with BUG/BUG_ON etc. need linux/bug.h 2012-03-04 17:54:34 -05:00
hash.h net: cleanup unsigned to unsigned int 2012-04-15 12:44:40 -04:00
ipv4.h ipv4: tcp: remove per net tcp_sock 2012-07-19 10:35:30 -07:00
ipv6.h inetpeer: add namespace support for inetpeer 2012-06-08 14:27:23 -07:00
mib.h net: use IS_ENABLED(CONFIG_IPV6) 2011-12-11 18:25:16 -05:00
packet.h packet: convert socket list to RCU (v3) 2010-02-22 15:45:56 -08:00
unix.h
x_tables.h net, netns_xt: shrink netns_xt members 2009-07-05 19:16:18 -07:00
xfrm.h net: use IS_ENABLED(CONFIG_IPV6) 2011-12-11 18:25:16 -05:00