Phonet: fix race for port number in concurrent bind()
authorRémi Denis-Courmont <remi.denis-courmont@nokia.com>
Wed, 23 Sep 2009 03:17:10 +0000 (03:17 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 24 Sep 2009 22:38:54 +0000 (15:38 -0700)
Allocating a port number to a socket and hashing that socket shall be
an atomic operation with regards to other port allocation. Otherwise,
we could allocate a port that is already being allocated to another
socket.

Signed-off-by: Rémi Denis-Courmont <remi.denis-courmont@nokia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

No differences found