Re: rxrpc: Fix deadlock between call creation and sendmsg/recvmsg

2017-03-02 Thread David Howells
Colin Ian King wrote: > I think the following part of the patch is problematic: > > call = rxrpc_find_call_by_user_ID(rx, user_call_ID); > if (!call) { > + ret = -EBADSLT; > if (cmd != RXRPC_CMD_SEND_DATA) > - return -EBADSLT; >

re: rxrpc: Fix deadlock between call creation and sendmsg/recvmsg

2017-03-02 Thread Colin Ian King
I think the following part of the patch is problematic: call = rxrpc_find_call_by_user_ID(rx, user_call_ID); if (!call) { + ret = -EBADSLT; if (cmd != RXRPC_CMD_SEND_DATA) - return -EBADSLT; + goto error_rel

Re: [PATCH net] rxrpc: Fix deadlock between call creation and sendmsg/recvmsg

2017-03-01 Thread David Miller
From: David Howells Date: Mon, 27 Feb 2017 15:43:06 + > All the routines by which rxrpc is accessed from the outside are serialised > by means of the socket lock (sendmsg, recvmsg, bind, > rxrpc_kernel_begin_call(), ...) and this presents a problem: ... > Fix this by: ... > This patch has t

[PATCH net] rxrpc: Fix deadlock between call creation and sendmsg/recvmsg

2017-02-27 Thread David Howells
All the routines by which rxrpc is accessed from the outside are serialised by means of the socket lock (sendmsg, recvmsg, bind, rxrpc_kernel_begin_call(), ...) and this presents a problem: (1) If a number of calls on the same socket are in the process of connection to the same peer, a maxim