]> git.baikalelectronics.ru Git - kernel.git/commit
xprtrdma: Destroy reps from previous connection instance
authorChuck Lever <chuck.lever@oracle.com>
Fri, 3 Jan 2020 16:57:04 +0000 (11:57 -0500)
committerAnna Schumaker <Anna.Schumaker@Netapp.com>
Wed, 15 Jan 2020 15:54:32 +0000 (10:54 -0500)
commit59a8ef2c5b6ca398f35dcac5e2f1af900db0bdbe
tree7ebfd8a43115ef8fc9aed3ea1298f53c7fbc7492
parent1d8f040282f58181bc7a99c836b8b2820a117927
xprtrdma: Destroy reps from previous connection instance

To safely get rid of all rpcrdma_reps from a particular connection
instance, xprtrdma has to wait until each of those reps is finished
being used. A rep may be backing the rq_rcv_buf of an RPC that has
just completed, for example.

Since it is safe to invoke rpcrdma_rep_destroy() only in the Receive
completion handler, simply mark reps remaining in the rb_all_reps
list after the transport is drained. These will then be deleted as
rpcrdma_post_recvs pulls them off the rep free list.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
net/sunrpc/xprtrdma/verbs.c