Skip to content

Commit

Permalink
scsi: FlashPoint: Remove redundant variable bm_int_st
Browse files Browse the repository at this point in the history
The variable bm_int_st is assigned a value but it is never read. The
variable and the assignment are redundant and can be removed.

Cleans up clang scan build warning:

  drivers/scsi/FlashPoint.c:1726:7: warning: Although the value stored
  to 'bm_int_st' is used in the enclosing expression, the value is never
  actually read from 'bm_int_st' [deadcode.DeadStores]

Link: https://lore.kernel.org/r/20220730123736.147758-1-colin.i.king@gmail.com
Acked-by: Khalid Aziz <khalid@gonehiking.org>
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
  • Loading branch information
Colin Ian King authored and Martin K. Petersen committed Aug 1, 2022
1 parent 4da8c5f commit 554b117
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/scsi/FlashPoint.c
Original file line number Diff line number Diff line change
Expand Up @@ -1712,7 +1712,7 @@ static unsigned char FlashPoint_InterruptPending(void *pCurrCard)
static int FlashPoint_HandleInterrupt(void *pcard)
{
struct sccb *currSCCB;
unsigned char thisCard, result, bm_status, bm_int_st;
unsigned char thisCard, result, bm_status;
unsigned short hp_int;
unsigned char i, target;
struct sccb_card *pCurrCard = pcard;
Expand All @@ -1723,7 +1723,7 @@ static int FlashPoint_HandleInterrupt(void *pcard)

MDISABLE_INT(ioport);

if ((bm_int_st = RD_HARPOON(ioport + hp_int_status)) & EXT_STATUS_ON)
if (RD_HARPOON(ioport + hp_int_status) & EXT_STATUS_ON)
bm_status = RD_HARPOON(ioport + hp_ext_status) &
(unsigned char)BAD_EXT_STATUS;
else
Expand Down

0 comments on commit 554b117

Please sign in to comment.