mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-21 11:44:01 +08:00
scsi: pcmcia: nsp_cs: Remove unused variable 'dummy'
There is no need to populate an unused variable, even if the read is required. Fixes the following W=1 kernel build warning(s): drivers/scsi/pcmcia/nsp_cs.c: In function ‘nsp_cs_message’: drivers/scsi/pcmcia/nsp_cs.c:143:2: warning: function ‘nsp_cs_message’ might be a candidate for ‘gnu_printf’ format attribute [-Wsuggest-attribute=format] drivers/scsi/pcmcia/nsp_cs.c: In function ‘nsp_fifo_count’: drivers/scsi/pcmcia/nsp_cs.c:692:24: warning: variable ‘dummy’ set but not used [-Wunused-but-set-variable] Link: https://lore.kernel.org/r/20200707140055.2956235-9-lee.jones@linaro.org Cc: YOKOTA Hiroshi <yokota@netlab.is.tsukuba.ac.jp> Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
parent
af0b55d060
commit
97a3348342
@ -690,14 +690,14 @@ static int nsp_fifo_count(struct scsi_cmnd *SCpnt)
|
|||||||
{
|
{
|
||||||
unsigned int base = SCpnt->device->host->io_port;
|
unsigned int base = SCpnt->device->host->io_port;
|
||||||
unsigned int count;
|
unsigned int count;
|
||||||
unsigned int l, m, h, dummy;
|
unsigned int l, m, h;
|
||||||
|
|
||||||
nsp_index_write(base, POINTERCLR, POINTER_CLEAR | ACK_COUNTER);
|
nsp_index_write(base, POINTERCLR, POINTER_CLEAR | ACK_COUNTER);
|
||||||
|
|
||||||
l = nsp_index_read(base, TRANSFERCOUNT);
|
l = nsp_index_read(base, TRANSFERCOUNT);
|
||||||
m = nsp_index_read(base, TRANSFERCOUNT);
|
m = nsp_index_read(base, TRANSFERCOUNT);
|
||||||
h = nsp_index_read(base, TRANSFERCOUNT);
|
h = nsp_index_read(base, TRANSFERCOUNT);
|
||||||
dummy = nsp_index_read(base, TRANSFERCOUNT); /* required this! */
|
nsp_index_read(base, TRANSFERCOUNT); /* required this! */
|
||||||
|
|
||||||
count = (h << 16) | (m << 8) | (l << 0);
|
count = (h << 16) | (m << 8) | (l << 0);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user