All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] scsi: lpfc: remove unneeded variable
@ 2021-08-31 11:40 cgel.zte
  2021-09-02 18:11 ` James Smart
  2021-09-14  3:43 ` Martin K. Petersen
  0 siblings, 2 replies; 6+ messages in thread
From: cgel.zte @ 2021-08-31 11:40 UTC (permalink / raw)
  To: james.smart
  Cc: dick.kennedy, jejb, martin.petersen, linux-scsi, linux-kernel,
	Chi Minghao, Zeal Robot

From: Chi Minghao <chi.minghao@zte.com.cn>

Fix the following coccicheck REVIEW:
./drivers/scsi/lpfc/lpfc_scsi.c:1498:9-12 REVIEW Unneeded variable

Reported-by: Zeal Robot <zealci@zte.com.cm>
Signed-off-by: Chi Minghao <chi.minghao@zte.com.cn>
---
 drivers/scsi/lpfc/lpfc_scsi.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/scsi/lpfc/lpfc_scsi.c b/drivers/scsi/lpfc/lpfc_scsi.c
index 0fde1e874c7a..08a6ad79ceef 100644
--- a/drivers/scsi/lpfc/lpfc_scsi.c
+++ b/drivers/scsi/lpfc/lpfc_scsi.c
@@ -1495,7 +1495,6 @@ static int
 lpfc_bg_err_opcodes(struct lpfc_hba *phba, struct scsi_cmnd *sc,
 		uint8_t *txop, uint8_t *rxop)
 {
-	uint8_t ret = 0;
 
 	if (sc->prot_flags & SCSI_PROT_IP_CHECKSUM) {
 		switch (scsi_get_prot_op(sc)) {
@@ -1548,7 +1547,7 @@ lpfc_bg_err_opcodes(struct lpfc_hba *phba, struct scsi_cmnd *sc,
 		}
 	}
 
-	return ret;
+	return 0;
 }
 #endif
 
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH] scsi: lpfc: remove unneeded variable
  2021-08-31 11:40 [PATCH] scsi: lpfc: remove unneeded variable cgel.zte
@ 2021-09-02 18:11 ` James Smart
  2021-09-14  3:43 ` Martin K. Petersen
  1 sibling, 0 replies; 6+ messages in thread
From: James Smart @ 2021-09-02 18:11 UTC (permalink / raw)
  To: cgel.zte, james.smart
  Cc: dick.kennedy, jejb, martin.petersen, linux-scsi, linux-kernel,
	Chi Minghao, Zeal Robot

On 8/31/2021 4:40 AM, cgel.zte@gmail.com wrote:
> From: Chi Minghao <chi.minghao@zte.com.cn>
> 
> Fix the following coccicheck REVIEW:
> ./drivers/scsi/lpfc/lpfc_scsi.c:1498:9-12 REVIEW Unneeded variable
> 
> Reported-by: Zeal Robot <zealci@zte.com.cm>
> Signed-off-by: Chi Minghao <chi.minghao@zte.com.cn>
> ---
>   drivers/scsi/lpfc/lpfc_scsi.c | 3 +--
>   1 file changed, 1 insertion(+), 2 deletions(-)

Looks Good - Thanks!

Reviewed-by: James Smart <jsmart2021@gmail.com>

-- james

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] scsi: lpfc: remove unneeded variable
  2021-08-31 11:40 [PATCH] scsi: lpfc: remove unneeded variable cgel.zte
  2021-09-02 18:11 ` James Smart
@ 2021-09-14  3:43 ` Martin K. Petersen
  1 sibling, 0 replies; 6+ messages in thread
From: Martin K. Petersen @ 2021-09-14  3:43 UTC (permalink / raw)
  To: james.smart, cgel.zte
  Cc: Martin K . Petersen, jejb, dick.kennedy, Zeal Robot, linux-scsi,
	Chi Minghao, linux-kernel

On Tue, 31 Aug 2021 04:40:58 -0700, cgel.zte@gmail.com wrote:

> From: Chi Minghao <chi.minghao@zte.com.cn>
> 
> Fix the following coccicheck REVIEW:
> ./drivers/scsi/lpfc/lpfc_scsi.c:1498:9-12 REVIEW Unneeded variable
> 
> 

Applied to 5.15/scsi-fixes, thanks!

[1/1] scsi: lpfc: remove unneeded variable
      https://git.kernel.org/mkp/scsi/c/5d1e15108b8d

-- 
Martin K. Petersen	Oracle Linux Engineering

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] scsi: lpfc: Remove unneeded variable
  2022-04-19  6:57 [PATCH] scsi: lpfc: Remove " cgel.zte
@ 2022-05-03  0:51 ` Martin K. Petersen
  0 siblings, 0 replies; 6+ messages in thread
From: Martin K. Petersen @ 2022-05-03  0:51 UTC (permalink / raw)
  To: cgel.zte, james.smart
  Cc: Martin K . Petersen, linux-kernel, jejb, Zeal Robot,
	Changcheng Deng, linux-scsi, dick.kennedy

On Tue, 19 Apr 2022 06:57:50 +0000, cgel.zte@gmail.com wrote:

> From: Changcheng Deng <deng.changcheng@zte.com.cn>
> 
> Remove unneeded variable used to store return value.
> 
> 

Applied to 5.19/scsi-queue, thanks!

[1/1] scsi: lpfc: Remove unneeded variable
      https://git.kernel.org/mkp/scsi/c/a346f28ad231

-- 
Martin K. Petersen	Oracle Linux Engineering

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH] scsi: lpfc: Remove unneeded variable
@ 2022-04-19  6:57 cgel.zte
  2022-05-03  0:51 ` Martin K. Petersen
  0 siblings, 1 reply; 6+ messages in thread
From: cgel.zte @ 2022-04-19  6:57 UTC (permalink / raw)
  To: james.smart
  Cc: dick.kennedy, jejb, martin.petersen, linux-scsi, linux-kernel,
	Changcheng Deng, Zeal Robot

From: Changcheng Deng <deng.changcheng@zte.com.cn>

Remove unneeded variable used to store return value.

Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Changcheng Deng <deng.changcheng@zte.com.cn>
---
 drivers/scsi/lpfc/lpfc_sli.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/scsi/lpfc/lpfc_sli.c b/drivers/scsi/lpfc/lpfc_sli.c
index bda2a7ba4e77..328b8f4440ef 100644
--- a/drivers/scsi/lpfc/lpfc_sli.c
+++ b/drivers/scsi/lpfc/lpfc_sli.c
@@ -3717,7 +3717,6 @@ lpfc_sli_process_sol_iocb(struct lpfc_hba *phba, struct lpfc_sli_ring *pring,
 			  struct lpfc_iocbq *saveq)
 {
 	struct lpfc_iocbq *cmdiocbp;
-	int rc = 1;
 	unsigned long iflag;
 	u32 ulp_command, ulp_status, ulp_word4, ulp_context, iotag;
 
@@ -3857,7 +3856,7 @@ lpfc_sli_process_sol_iocb(struct lpfc_hba *phba, struct lpfc_sli_ring *pring,
 		}
 	}
 
-	return rc;
+	return 1;
 }
 
 /**
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH] scsi: lpfc: remove unneeded variable
@ 2021-11-12 13:02 cgel.zte
  0 siblings, 0 replies; 6+ messages in thread
From: cgel.zte @ 2021-11-12 13:02 UTC (permalink / raw)
  To: james.smart
  Cc: dick.kennedy, jejb, martin.petersen, linux-scsi, linux-kernel,
	Changcheng Deng, Zeal Robot

From: Changcheng Deng <deng.changcheng@zte.com.cn>

Fix the following coccicheck review:
./drivers/scsi/lpfc/lpfc_sli.c: 3655: 5-7: Unneeded variable

Remove unneeded variable used to store return value.

Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Changcheng Deng <deng.changcheng@zte.com.cn>
---
 drivers/scsi/lpfc/lpfc_sli.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/scsi/lpfc/lpfc_sli.c b/drivers/scsi/lpfc/lpfc_sli.c
index 53f154a301b5..93596cdd66a7 100644
--- a/drivers/scsi/lpfc/lpfc_sli.c
+++ b/drivers/scsi/lpfc/lpfc_sli.c
@@ -3652,7 +3652,6 @@ lpfc_sli_process_sol_iocb(struct lpfc_hba *phba, struct lpfc_sli_ring *pring,
 			  struct lpfc_iocbq *saveq)
 {
 	struct lpfc_iocbq *cmdiocbp;
-	int rc = 1;
 	unsigned long iflag;
 
 	cmdiocbp = lpfc_sli_iocbq_lookup(phba, pring, saveq);
@@ -3777,7 +3776,7 @@ lpfc_sli_process_sol_iocb(struct lpfc_hba *phba, struct lpfc_sli_ring *pring,
 		}
 	}
 
-	return rc;
+	return 1;
 }
 
 /**
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2022-05-04  3:38 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-31 11:40 [PATCH] scsi: lpfc: remove unneeded variable cgel.zte
2021-09-02 18:11 ` James Smart
2021-09-14  3:43 ` Martin K. Petersen
2021-11-12 13:02 cgel.zte
2022-04-19  6:57 [PATCH] scsi: lpfc: Remove " cgel.zte
2022-05-03  0:51 ` Martin K. Petersen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.