Subject: Re: [PATCH 1/2] tcp: Fix a connect() race with timewait sockets

From: Evgeniy Polyakov <[email-masked]>
Date: Sun, 6 Dec 2009 00:21:48 +0300

Hi Eric.

On Fri, Dec 04, 2009 at 02:46:54PM +0100, Eric Dumazet ([email-masked]) wrote:
> First patch changes __inet_hash_nolisten() and __inet6_hash()
> to get a timewait parameter to be able to unhash it from ehash
> at same time the new socket is inserted in hash.
> 
> This makes sure timewait socket wont be found by a concurrent
> writer in __inet_check_established()

Both patches look good, although trick with returning reference counter
may look like a hack especially when only viewing into ip code and not
hashtable itself. Can you please cook up a documentation update for hash
function that it is supposed to return refcnt when socket was in hash
table.

-- 
	Evgeniy Polyakov