[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <BY5PR11MB38631F80136B45251549AC02C3360@BY5PR11MB3863.namprd11.prod.outlook.com>
Date: Fri, 25 Sep 2020 06:58:59 +0000
From: "Karan Tilak Kumar (kartilak)" <kartilak@...co.com>
To: Jing Xiangfeng <jingxiangfeng@...wei.com>,
"Sesidhar Baddela (sebaddel)" <sebaddel@...co.com>,
"jejb@...ux.ibm.com" <jejb@...ux.ibm.com>,
"martin.petersen@...cle.com" <martin.petersen@...cle.com>
CC: "linux-scsi@...r.kernel.org" <linux-scsi@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH] scsi: snic: Remove unnecessary condition to simplify the
code
Looks good to me.
Signed off by: Karan Tilak Kumar <kartilak@...co.com>
Regards,
Karan
-----Original Message-----
From: Jing Xiangfeng <jingxiangfeng@...wei.com>
Sent: Thursday, September 24, 2020 11:08 PM
To: Karan Tilak Kumar (kartilak) <kartilak@...co.com>; Sesidhar Baddela (sebaddel) <sebaddel@...co.com>; jejb@...ux.ibm.com; martin.petersen@...cle.com
Cc: linux-scsi@...r.kernel.org; linux-kernel@...r.kernel.org; jingxiangfeng@...wei.com
Subject: [PATCH] scsi: snic: Remove unnecessary condition to simplify the code
ret is always zero or an error in this code path. So the assignment to ret is redundant, and the code jumping to a label is unneed.
Let's remove them to simplify the code. No functional changes.
Signed-off-by: Jing Xiangfeng <jingxiangfeng@...wei.com>
---
drivers/scsi/snic/snic_scsi.c | 4 ----
1 file changed, 4 deletions(-)
diff --git a/drivers/scsi/snic/snic_scsi.c b/drivers/scsi/snic/snic_scsi.c index b3650c989ed4..0c2f31b8ea05 100644
--- a/drivers/scsi/snic/snic_scsi.c
+++ b/drivers/scsi/snic/snic_scsi.c
@@ -1387,10 +1387,6 @@ snic_issue_tm_req(struct snic *snic,
}
ret = snic_queue_itmf_req(snic, tmreq, sc, tmf, req_id);
- if (ret)
- goto tmreq_err;
-
- ret = 0;
tmreq_err:
if (ret) {
--
2.17.1
Powered by blists - more mailing lists