linux/net/sunrpc/xprtrdma
Trond Myklebust f99fa50880 SUNRPC/xprtrdma: Fix reconnection locking
The xprtrdma client code currently relies on the task that initiated the
connect to hold the XPRT_LOCK for the duration of the connection
attempt. If the task is woken early, due to some other event, then that
lock could get released early.
Avoid races by using the same mechanism that the socket code uses of
transferring lock ownership to the RDMA connect worker itself. That
frees us to call rpcrdma_xprt_disconnect() directly since we're now
guaranteed exclusion w.r.t. other callers.

Fixes: 4cf44be6f1 ("xprtrdma: Fix recursion into rpcrdma_xprt_disconnect()")
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
2021-08-09 16:57:05 -04:00
..
backchannel.c xprtrdma: Eliminate rpcrdma_post_sends() 2021-08-09 16:42:25 -04:00
frwr_ops.c xprtrdma: Add an xprtrdma_post_send_err tracepoint 2021-08-09 16:42:18 -04:00
Makefile svcrdma: Add a "parsed chunk list" data structure 2020-11-30 13:00:22 -05:00
module.c SUNRPC: xprt_load_transport() needs to support the netid "rdma6" 2020-12-02 14:05:52 -05:00
rpc_rdma.c xprtrdma: Revert 586a0787ce 2021-05-27 08:46:19 -04:00
svc_rdma_backchannel.c svcrdma: Normalize Send page handling 2021-03-22 13:22:13 -04:00
svc_rdma_pcl.c svcrdma: Add a "parsed chunk list" data structure 2020-11-30 13:00:22 -05:00
svc_rdma_recvfrom.c svcrdma: Clean up dto_q critical section in svc_rdma_recvfrom() 2021-03-31 15:58:48 -04:00
svc_rdma_rw.c xprtrdma: Fix spelling mistakes 2021-07-06 20:14:41 -04:00
svc_rdma_sendto.c svcrdma: Pass a useful error code to the send_err tracepoint 2021-04-14 12:09:27 -04:00
svc_rdma_transport.c svcrdma: Remove sc_read_complete_q 2021-03-31 15:57:48 -04:00
svc_rdma.c svcrdma: Deprecate stat variables that are no longer used 2021-01-25 09:36:28 -05:00
transport.c SUNRPC/xprtrdma: Fix reconnection locking 2021-08-09 16:57:05 -04:00
verbs.c xprtrdma: Eliminate rpcrdma_post_sends() 2021-08-09 16:42:25 -04:00
xprt_rdma.h xprtrdma: Eliminate rpcrdma_post_sends() 2021-08-09 16:42:25 -04:00