Skip to content

Commit

Permalink
scsi: qla1280: Remove set but not used variable in qla1280_nvram_conf…
Browse files Browse the repository at this point in the history
…ig()

This addresses the following gcc warning with "make W=1":

drivers/scsi/qla1280.c: In function ‘qla1280_nvram_config’:
drivers/scsi/qla1280.c:2188:36: warning: variable ‘ddma_conf’ set but
not used [-Wunused-but-set-variable]
 2188 |   uint16_t hwrev, cfg1, cdma_conf, ddma_conf;
      |                                    ^~~~~~~~~

Link: https://lore.kernel.org/r/[email protected]
Reported-by: Hulk Robot <[email protected]>
Signed-off-by: Jason Yan <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
  • Loading branch information
JasonYanHw authored and martinkpetersen committed Sep 10, 2020
1 parent 3eedb42 commit 9b0f9e5
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/scsi/qla1280.c
Original file line number Diff line number Diff line change
Expand Up @@ -2184,13 +2184,12 @@ qla1280_nvram_config(struct scsi_qla_host *ha)
nv->cntr_flags_1.disable_loading_risc_code;

if (IS_ISP1040(ha)) {
uint16_t hwrev, cfg1, cdma_conf, ddma_conf;
uint16_t hwrev, cfg1, cdma_conf;

hwrev = RD_REG_WORD(&reg->cfg_0) & ISP_CFG0_HWMSK;

cfg1 = RD_REG_WORD(&reg->cfg_1) & ~(BIT_4 | BIT_5 | BIT_6);
cdma_conf = RD_REG_WORD(&reg->cdma_cfg);
ddma_conf = RD_REG_WORD(&reg->ddma_cfg);

/* Busted fifo, says mjacob. */
if (hwrev != ISP_CFG0_1040A)
Expand Down

0 comments on commit 9b0f9e5

Please sign in to comment.