mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-15 08:44:14 +08:00
xprtrdma: checking for NULL instead of IS_ERR()
The rpcrdma_create_req() function returns error pointers or success. It
never returns NULL.
Fixes: f531a5dbc4
('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>
This commit is contained in:
parent
38b95bcf12
commit
abfb689711
@ -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);
|
||||
|
Loading…
Reference in New Issue
Block a user