diff mbox series

[-next] scsi: lpfc: Remove set but not used variables 'qp'

Message ID 20190531152745.7928-1-yuehaibing@huawei.com (mailing list archive)
State Mainlined
Commit a82b3539dc27b3a85f0c46c9bc398734fdd08260
Headers show
Series [-next] scsi: lpfc: Remove set but not used variables 'qp' | expand

Commit Message

Yue Haibing May 31, 2019, 3:27 p.m. UTC
Fixes gcc '-Wunused-but-set-variable' warnings:

drivers/scsi/lpfc/lpfc_init.c: In function lpfc_setup_cq_lookup:
drivers/scsi/lpfc/lpfc_init.c:9359:30: warning: variable qp set but not used [-Wunused-but-set-variable]

It's not used since commit e70596a60f88 ("scsi: lpfc: Fix
poor use of hardware queues if fewer irq vectors")

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 drivers/scsi/lpfc/lpfc_init.c | 2 --
 1 file changed, 2 deletions(-)

Comments

James Smart June 4, 2019, 5:34 p.m. UTC | #1
On 5/31/2019 8:27 AM, YueHaibing wrote:
> Fixes gcc '-Wunused-but-set-variable' warnings:
>
> drivers/scsi/lpfc/lpfc_init.c: In function lpfc_setup_cq_lookup:
> drivers/scsi/lpfc/lpfc_init.c:9359:30: warning: variable qp set but not used [-Wunused-but-set-variable]
>
> It's not used since commit e70596a60f88 ("scsi: lpfc: Fix
> poor use of hardware queues if fewer irq vectors")
>
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
>

Looks good - thank You

Reviewed-by: James SmartĀ  <james.smart@broadcom.com>
Martin K. Petersen June 5, 2019, 2:30 a.m. UTC | #2
YueHaibing,

> Fixes gcc '-Wunused-but-set-variable' warnings:
>
> drivers/scsi/lpfc/lpfc_init.c: In function lpfc_setup_cq_lookup:
> drivers/scsi/lpfc/lpfc_init.c:9359:30: warning: variable qp set but not used [-Wunused-but-set-variable]

Applied to 5.3/scsi-queue, thanks.
diff mbox series

Patch

diff --git a/drivers/scsi/lpfc/lpfc_init.c b/drivers/scsi/lpfc/lpfc_init.c
index 24965a06f55d..cd8e47544d07 100644
--- a/drivers/scsi/lpfc/lpfc_init.c
+++ b/drivers/scsi/lpfc/lpfc_init.c
@@ -9356,10 +9356,8 @@  static void
 lpfc_setup_cq_lookup(struct lpfc_hba *phba)
 {
 	struct lpfc_queue *eq, *childq;
-	struct lpfc_sli4_hdw_queue *qp;
 	int qidx;
 
-	qp = phba->sli4_hba.hdwq;
 	memset(phba->sli4_hba.cq_lookup, 0,
 	       (sizeof(struct lpfc_queue *) * (phba->sli4_hba.cq_max + 1)));
 	/* Loop thru all IRQ vectors */