xprtrdma: Decode credits field in rpcrdma_reply_handler
authorChuck Lever <chuck.lever@oracle.com>
Mon, 16 Oct 2017 19:01:39 +0000 (15:01 -0400)
committerAnna Schumaker <Anna.Schumaker@Netapp.com>
Fri, 17 Nov 2017 18:47:55 +0000 (13:47 -0500)
commitbe798f9082aa54524b209fac2c8164c81cd28f77
tree146ed327e4138a89734e63ffe7bc839604d11bfd
parentd8f532d20ee43a0117284798d486bc4f98e3b196
xprtrdma: Decode credits field in rpcrdma_reply_handler

We need to decode and save the incoming rdma_credits field _after_
we know that the direction of the message is "forward direction
Reply". Otherwise, the credits value in reverse direction Calls is
also used to update the forward direction credits.

It is safe to decode the rdma_credits field in rpcrdma_reply_handler
now that rpcrdma_reply_handler is single-threaded. Receives complete
in the same order as they were sent on the NFS server.

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