projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
38b95bc
)
xprtrdma: checking for NULL instead of IS_ERR()
author
Dan Carpenter
<dan.carpenter@oracle.com>
Thu, 5 Nov 2015 08:39:52 +0000
(11:39 +0300)
committer
Anna Schumaker
<Anna.Schumaker@Netapp.com>
Fri, 18 Dec 2015 20:34:33 +0000
(15:34 -0500)
The rpcrdma_create_req() function returns error pointers or success. It
never returns NULL.
Fixes: f531a5dbc451 ('xprtrdma: Pre-allocate backward rpc_rqst and send/receive buffers')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
net/sunrpc/xprtrdma/backchannel.c
patch
|
blob
|
history
diff --git
a/net/sunrpc/xprtrdma/backchannel.c
b/net/sunrpc/xprtrdma/backchannel.c
index 2dcb44f69e539e530c208086acb4a1bee6e710ee..97554ca68191537a17e6e6c32c08bde523b20fa5 100644
(file)
--- a/
net/sunrpc/xprtrdma/backchannel.c
+++ b/
net/sunrpc/xprtrdma/backchannel.c
@@
-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);