From: Herbert Xu Date: Tue, 3 May 2005 21:43:27 +0000 (-0700) Subject: [NETLINK]: cb_lock does not needs ref count on sk X-Git-Tag: v2.6.12-rc4~117^2~23^2~11 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=96c36023434b7b6824b1da72a6b7b1ca61d7310c;p=pandora-kernel.git [NETLINK]: cb_lock does not needs ref count on sk Here is a little optimisation for the cb_lock used by netlink_dump. While fixing that race earlier, I noticed that the reference count held by cb_lock is completely useless. The reason is that in order to obtain the protection of the reference count, you have to take the cb_lock. But the only way to take the cb_lock is through dereferencing the socket. That is, you must already possess a reference count on the socket before you can take advantage of the reference count held by cb_lock. As a corollary, we can remve the reference count held by the cb_lock. Signed-off-by: Herbert Xu Signed-off-by: David S. Miller --- Reading git-diff-tree failed