]> git.baikalelectronics.ru Git - kernel.git/commit
tipc: wakeup sleeping users at disconnect
authorParthasarathy Bhuvaragan <parthasarathy.bhuvaragan@ericsson.com>
Tue, 1 Nov 2016 13:02:35 +0000 (14:02 +0100)
committerDavid S. Miller <davem@davemloft.net>
Tue, 1 Nov 2016 15:53:23 +0000 (11:53 -0400)
commitaa208eb54ef283ab615dccf4fcc3d5ea8a0c53b7
treef3ad15f6e2f7ea777faae2667cb5643f3bc5670c
parent1047aab58ab811396771b352a690667369526e46
tipc: wakeup sleeping users at disconnect

Until now, in filter_connect() when we terminate a connection due to
an error message from peer, we set the socket state to DISCONNECTING.

The socket is notified about this broken connection using EPIPE when
a user tries to send a message. However if a socket was waiting on a
poll() while the connection is being terminated, we fail to wakeup
that socket.

In this commit, we wakeup sleeping sockets at connection termination.

Acked-by: Jon Maloy <jon.maloy@ericsson.com>
Signed-off-by: Parthasarathy Bhuvaragan <parthasarathy.bhuvaragan@ericsson.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tipc/socket.c