]> git.baikalelectronics.ru Git - kernel.git/commit
unix_diag: Pending connections IDs NLA
authorPavel Emelyanov <xemul@parallels.com>
Thu, 15 Dec 2011 02:46:14 +0000 (02:46 +0000)
committerDavid S. Miller <davem@davemloft.net>
Fri, 16 Dec 2011 18:48:28 +0000 (13:48 -0500)
commitc1ef5ad2222c3898060ffe6618a256941447ab62
treea2308c69d4a03fdb99596f336b7cdfeb6692c7a8
parent4e8ce1455648c3889182c037f88cd9ec049dbca4
unix_diag: Pending connections IDs NLA

When establishing a unix connection on stream sockets the
server end receives an skb with socket in its receive queue.

Report who is waiting for these ends to be accepted for
listening sockets via NLA.

There's a lokcing issue with this -- the unix sk state lock is
required to access the peer, and it is taken under the listening
sk's queue lock. Strictly speaking the queue lock should be taken
inside the state lock, but since in this case these two sockets
are different it shouldn't lead to deadlock.

Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/unix_diag.h
net/unix/diag.c