]> git.baikalelectronics.ru Git - kernel.git/commit
Merge branch 'tcp_dccp_ports'
authorDavid S. Miller <davem@davemloft.net>
Fri, 12 Feb 2016 10:28:38 +0000 (05:28 -0500)
committerDavid S. Miller <davem@davemloft.net>
Fri, 12 Feb 2016 10:28:38 +0000 (05:28 -0500)
commitf6a6e9c0c65f4ad370f9468f7a3e802cb612b228
tree8b75745c913c33eba2707c3dc5fb0e312bfe3387
parentbaf0c59c768cc59a0546a70863ed7a1e39d5995e
parenta20abb750f3f862c3a246eaaedf63ec178540ed8
Merge branch 'tcp_dccp_ports'

Eric Dumazet says:

====================
tcp/dccp: better use of ephemeral ports

Big servers have bloated bind table, making very hard to succeed
ephemeral port allocations, without special containers/namespace tricks.

This patch series extends the strategy added in commit 63e4fadda7ad
("tcp/dccp: try to not exhaust ip_local_port_range in connect()").

Since ports used by connect() are much likely to be shared among them,
we give a hint to both bind() and connect() to keep the crowds separated
if possible.

Of course, if on a specific host an application needs to allocate ~30000
ports using bind(), it will still be able to do so. Same for ~30000 connect()
to a unique 2-tuple (dst addr, dst port)

New implemetation is also more friendly to softirqs and reschedules.

v2: rebase after TCP SO_REUSEPORT changes
====================

Signed-off-by: David S. Miller <davem@davemloft.net>