summaryrefslogtreecommitdiffstats
path: root/net/sunrpc/xprtrdma/transport.c
diff options
context:
space:
mode:
authorChuck Lever2014-05-28 16:35:06 +0200
committerAnna Schumaker2014-06-04 14:56:53 +0200
commitc977dea22708688eae31774f70126c97aa4dfe83 (patch)
tree241908e348cc6bd47aae22fd1cea738e6686cf40 /net/sunrpc/xprtrdma/transport.c
parentxprtrdma: Avoid deadlock when credit window is reset (diff)
downloadkernel-qcow2-linux-c977dea22708688eae31774f70126c97aa4dfe83.tar.gz
kernel-qcow2-linux-c977dea22708688eae31774f70126c97aa4dfe83.tar.xz
kernel-qcow2-linux-c977dea22708688eae31774f70126c97aa4dfe83.zip
xprtrdma: Remove BUG_ON() call sites
If an error occurs in the marshaling logic, fail the RPC request being processed, but leave the client running. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Diffstat (limited to 'net/sunrpc/xprtrdma/transport.c')
-rw-r--r--net/sunrpc/xprtrdma/transport.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/sunrpc/xprtrdma/transport.c b/net/sunrpc/xprtrdma/transport.c
index 187894b4c33f..93fe7753ff94 100644
--- a/net/sunrpc/xprtrdma/transport.c
+++ b/net/sunrpc/xprtrdma/transport.c
@@ -463,7 +463,8 @@ xprt_rdma_allocate(struct rpc_task *task, size_t size)
struct rpcrdma_req *req, *nreq;
req = rpcrdma_buffer_get(&rpcx_to_rdmax(xprt)->rx_buf);
- BUG_ON(NULL == req);
+ if (req == NULL)
+ return NULL;
if (size > req->rl_size) {
dprintk("RPC: %s: size %zd too large for buffer[%zd]: "