cifsd: fix static checker warning from smb_direct_post_send_data()

Dan reported static checker warning:
 fs/cifsd/transport_rdma.c:1168 smb_direct_post_send_data()
 warn: missing error code 'ret'

This patch add missing ret error code.

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Namjae Jeon <namjae.jeon@samsung.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
This commit is contained in:
Namjae Jeon 2021-03-19 13:51:15 +09:00 committed by Steve French
parent a2ba2709f5
commit bc3fcc9462
1 changed files with 1 additions and 0 deletions

View File

@ -1165,6 +1165,7 @@ static int smb_direct_post_send_data(struct smb_direct_transport *t,
sg, SMB_DIRECT_MAX_SEND_SGES-1, DMA_TO_DEVICE);
if (sg_cnt <= 0) {
ksmbd_err("failed to map buffer\n");
ret = -ENOMEM;
goto err;
} else if (sg_cnt + msg->num_sge > SMB_DIRECT_MAX_SEND_SGES-1) {
ksmbd_err("buffer not fitted into sges\n");