diff options
author | Colin Ian King <colin.i.king@gmail.com> | 2024-04-15 11:43:11 +0100 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2024-04-24 21:13:41 -0400 |
commit | cb3bfbfa1ffab89e10c093e3bfcc4cf229ad5ab7 (patch) | |
tree | 91991e0b40d829f652543b8d9743c19de657647f /drivers/scsi/bnx2fc | |
parent | 28027ec8e32ecbadcd67623edb290dad61e735b5 (diff) | |
download | linux-stable-cb3bfbfa1ffab89e10c093e3bfcc4cf229ad5ab7.tar.gz linux-stable-cb3bfbfa1ffab89e10c093e3bfcc4cf229ad5ab7.tar.bz2 linux-stable-cb3bfbfa1ffab89e10c093e3bfcc4cf229ad5ab7.zip |
scsi: bnx2fc: Remove redundant assignment to variable 'i'
The variable 'i' is being assigned a value that is never read, the
following code path via the label ofld_err never refers to the
variable. The assignment is redundant and can be removed.
Cleans up clang scan warning:
drivers/scsi/bnx2fc/bnx2fc_tgt.c:132:5: warning: Value stored to 'i'
is never read [deadcode.DeadStores]
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Link: https://lore.kernel.org/r/20240415104311.484890-1-colin.i.king@gmail.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/bnx2fc')
-rw-r--r-- | drivers/scsi/bnx2fc/bnx2fc_tgt.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/scsi/bnx2fc/bnx2fc_tgt.c b/drivers/scsi/bnx2fc/bnx2fc_tgt.c index 2c246e80c1c4..253e25d4c489 100644 --- a/drivers/scsi/bnx2fc/bnx2fc_tgt.c +++ b/drivers/scsi/bnx2fc/bnx2fc_tgt.c @@ -128,10 +128,8 @@ retry_ofld: BNX2FC_TGT_DBG(tgt, "ctx_alloc_failure, " "retry ofld..%d\n", i++); msleep_interruptible(1000); - if (i > 3) { - i = 0; + if (i > 3) goto ofld_err; - } goto retry_ofld; } goto ofld_err; |