diff mbox series

[linux-next] scsi: message: Remove the unneeded result variable

Message ID 20220905090037.335055-1-ye.xingchen@zte.com.cn (mailing list archive)
State Deferred
Headers show
Series [linux-next] scsi: message: Remove the unneeded result variable | expand

Commit Message

CGEL Sept. 5, 2022, 9 a.m. UTC
From: ye xingchen <ye.xingchen@zte.com.cn>

Return the value mptctl_do_mpt_command() directly instead of storing it in
 another redundant variable.

Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn>
---
 drivers/message/fusion/mptctl.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)
diff mbox series

Patch

diff --git a/drivers/message/fusion/mptctl.c b/drivers/message/fusion/mptctl.c
index f9ee957072c3..1e13c41fd58e 100644
--- a/drivers/message/fusion/mptctl.c
+++ b/drivers/message/fusion/mptctl.c
@@ -1702,8 +1702,6 @@  mptctl_mpt_command (MPT_ADAPTER *ioc, unsigned long arg)
 {
 	struct mpt_ioctl_command __user *uarg = (void __user *) arg;
 	struct mpt_ioctl_command  karg;
-	int		rc;
-
 
 	if (copy_from_user(&karg, uarg, sizeof(struct mpt_ioctl_command))) {
 		printk(KERN_ERR MYNAM "%s@%d::mptctl_mpt_command - "
@@ -1712,9 +1710,7 @@  mptctl_mpt_command (MPT_ADAPTER *ioc, unsigned long arg)
 		return -EFAULT;
 	}
 
-	rc = mptctl_do_mpt_command (ioc, karg, &uarg->MF);
-
-	return rc;
+	return mptctl_do_mpt_command(ioc, karg, &uarg->MF);
 }
 
 /*=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=*/