提交 abfb6897 编写于 作者: D Dan Carpenter 提交者: Anna Schumaker

xprtrdma: checking for NULL instead of IS_ERR()

The rpcrdma_create_req() function returns error pointers or success.  It
never returns NULL.

Fixes: f531a5db ('xprtrdma: Pre-allocate backward rpc_rqst and send/receive buffers')
Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: NAnna Schumaker <Anna.Schumaker@Netapp.com>
上级 38b95bcf
......@@ -42,8 +42,8 @@ static int rpcrdma_bc_setup_rqst(struct rpcrdma_xprt *r_xprt,
size_t size;
req = rpcrdma_create_req(r_xprt);
if (!req)
return -ENOMEM;
if (IS_ERR(req))
return PTR_ERR(req);
req->rl_backchannel = true;
size = RPCRDMA_INLINE_WRITE_THRESHOLD(rqst);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册