]> www.infradead.org Git - users/jedix/linux-maple.git/commit
xprtrdma: Split rb_lock
authorChuck Lever <chuck.lever@oracle.com>
Tue, 25 Aug 2015 18:56:54 +0000 (12:56 -0600)
committerChuck Lever <chuck.lever@oracle.com>
Mon, 31 Aug 2015 20:45:57 +0000 (14:45 -0600)
commitb0008ee30b05970eb50628794ee313c51a545527
tree07b10fb0bee6e8a834202f3a089624d9188040e0
parentb9ae44e31ac38781b39f68b952c741fe192a82e1
xprtrdma: Split rb_lock

[ Upstream commit 58d1dcf5a8ebb0ce8a521286a99efdd636012bf0 ]

/proc/lock_stat showed contention between rpcrdma_buffer_get/put
and the MR allocation functions during I/O intensive workloads.

Now that MRs are no longer allocated in rpcrdma_buffer_get(),
there's no reason the rb_mws list has to be managed using the
same lock as the send/receive buffers. Split that lock. The
new lock does not need to disable interrupts because buffer
get/put is never called in an interrupt context.

struct rpcrdma_buffer is re-arranged to ensure rb_mwlock and rb_mws
are always in a different cacheline than rb_lock and the buffer
pointers.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Reviewed-by: Steve Wise <swise@opengridcomputing.com>
Reviewed-by: Sagi Grimberg <sagig@mellanox.com>
Tested-By: Devesh Sharma <devesh.sharma@avagotech.com>
Reviewed-by: Doug Ledford <dledford@redhat.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
net/sunrpc/xprtrdma/fmr_ops.c
net/sunrpc/xprtrdma/frwr_ops.c
net/sunrpc/xprtrdma/verbs.c
net/sunrpc/xprtrdma/xprt_rdma.h