* [PATCH] scsi: hisi_sas: remove set but not used variable 'irq_value'
@ 2019-08-22 14:20 zhengbin
2019-08-22 14:36 ` John Garry
2019-08-29 22:02 ` Martin K. Petersen
0 siblings, 2 replies; 3+ messages in thread
From: zhengbin @ 2019-08-22 14:20 UTC (permalink / raw)
To: john.garry, jejb, martin.petersen, linux-scsi; +Cc: yi.zhang, zhengbin13
Fixes gcc '-Wunused-but-set-variable' warning:
drivers/scsi/hisi_sas/hisi_sas_v1_hw.c: In function cq_interrupt_v1_hw:
drivers/scsi/hisi_sas/hisi_sas_v1_hw.c:1542:6: warning: variable irq_value set but not used [-Wunused-but-set-variable]
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: zhengbin <zhengbin13@huawei.com>
---
drivers/scsi/hisi_sas/hisi_sas_v1_hw.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/scsi/hisi_sas/hisi_sas_v1_hw.c b/drivers/scsi/hisi_sas/hisi_sas_v1_hw.c
index 3912216..b198adc 100644
--- a/drivers/scsi/hisi_sas/hisi_sas_v1_hw.c
+++ b/drivers/scsi/hisi_sas/hisi_sas_v1_hw.c
@@ -1534,11 +1534,9 @@ static irqreturn_t cq_interrupt_v1_hw(int irq, void *p)
struct hisi_sas_complete_v1_hdr *complete_queue =
(struct hisi_sas_complete_v1_hdr *)
hisi_hba->complete_hdr[queue];
- u32 irq_value, rd_point = cq->rd_point, wr_point;
+ u32 rd_point = cq->rd_point, wr_point;
spin_lock(&hisi_hba->lock);
- irq_value = hisi_sas_read32(hisi_hba, OQ_INT_SRC);
-
hisi_sas_write32(hisi_hba, OQ_INT_SRC, 1 << queue);
wr_point = hisi_sas_read32(hisi_hba,
COMPL_Q_0_WR_PTR + (0x14 * queue));
--
2.7.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] scsi: hisi_sas: remove set but not used variable 'irq_value'
2019-08-22 14:20 [PATCH] scsi: hisi_sas: remove set but not used variable 'irq_value' zhengbin
@ 2019-08-22 14:36 ` John Garry
2019-08-29 22:02 ` Martin K. Petersen
1 sibling, 0 replies; 3+ messages in thread
From: John Garry @ 2019-08-22 14:36 UTC (permalink / raw)
To: zhengbin, jejb, martin.petersen, linux-scsi; +Cc: yi.zhang
On 22/08/2019 15:20, zhengbin wrote:
> Fixes gcc '-Wunused-but-set-variable' warning:
>
> drivers/scsi/hisi_sas/hisi_sas_v1_hw.c: In function cq_interrupt_v1_hw:
> drivers/scsi/hisi_sas/hisi_sas_v1_hw.c:1542:6: warning: variable irq_value set but not used [-Wunused-but-set-variable]
>
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: zhengbin <zhengbin13@huawei.com>
> ---
Acked-by: John Garry <john.garry@huawei.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] scsi: hisi_sas: remove set but not used variable 'irq_value'
2019-08-22 14:20 [PATCH] scsi: hisi_sas: remove set but not used variable 'irq_value' zhengbin
2019-08-22 14:36 ` John Garry
@ 2019-08-29 22:02 ` Martin K. Petersen
1 sibling, 0 replies; 3+ messages in thread
From: Martin K. Petersen @ 2019-08-29 22:02 UTC (permalink / raw)
To: zhengbin; +Cc: john.garry, jejb, martin.petersen, linux-scsi, yi.zhang
zhengbin,
> Fixes gcc '-Wunused-but-set-variable' warning:
>
> drivers/scsi/hisi_sas/hisi_sas_v1_hw.c: In function cq_interrupt_v1_hw:
> drivers/scsi/hisi_sas/hisi_sas_v1_hw.c:1542:6: warning: variable irq_value set but not used [-Wunused-but-set-variable]
Applied to 5.4/scsi-queue, thanks.
--
Martin K. Petersen Oracle Linux Engineering
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-08-29 22:02 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-22 14:20 [PATCH] scsi: hisi_sas: remove set but not used variable 'irq_value' zhengbin
2019-08-22 14:36 ` John Garry
2019-08-29 22:02 ` Martin K. Petersen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).