* [PATCH] scsi: qla1280: remove redundant variable toke
@ 2022-05-18 10:21 Colin Ian King
2022-05-20 0:26 ` Martin K. Petersen
2022-05-24 3:27 ` Martin K. Petersen
0 siblings, 2 replies; 3+ messages in thread
From: Colin Ian King @ 2022-05-18 10:21 UTC (permalink / raw)
To: Michael Reed, James E . J . Bottomley, Martin K . Petersen, linux-scsi
Cc: kernel-janitors, linux-kernel
Variable toke is being assigned a value that is never read. The variable
is redundant, remove it.
Cleans up clang scan build warning:
warning: Although the value stored to 'toke' is used in the enclosing
expression, the value is never actually read from 'toke'
[deadcode.DeadStores]
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
---
drivers/scsi/qla1280.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/scsi/qla1280.c b/drivers/scsi/qla1280.c
index 0ab595c0870a..1e7f4d138e06 100644
--- a/drivers/scsi/qla1280.c
+++ b/drivers/scsi/qla1280.c
@@ -4037,7 +4037,6 @@ qla1280_setup(char *s)
{
char *cp, *ptr;
unsigned long val;
- int toke;
cp = s;
@@ -4052,7 +4051,7 @@ qla1280_setup(char *s)
} else
val = simple_strtoul(ptr, &ptr, 0);
- switch ((toke = qla1280_get_token(cp))) {
+ switch (qla1280_get_token(cp)) {
case TOKEN_NVRAM:
if (!val)
driver_setup.no_nvram = 1;
--
2.35.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] scsi: qla1280: remove redundant variable toke
2022-05-18 10:21 [PATCH] scsi: qla1280: remove redundant variable toke Colin Ian King
@ 2022-05-20 0:26 ` Martin K. Petersen
2022-05-24 3:27 ` Martin K. Petersen
1 sibling, 0 replies; 3+ messages in thread
From: Martin K. Petersen @ 2022-05-20 0:26 UTC (permalink / raw)
To: Colin Ian King
Cc: Michael Reed, James E . J . Bottomley, Martin K . Petersen,
linux-scsi, kernel-janitors, linux-kernel
Colin,
> Variable toke is being assigned a value that is never read. The
> variable is redundant, remove it.
Applied to 5.19/scsi-staging, thanks!
--
Martin K. Petersen Oracle Linux Engineering
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] scsi: qla1280: remove redundant variable toke
2022-05-18 10:21 [PATCH] scsi: qla1280: remove redundant variable toke Colin Ian King
2022-05-20 0:26 ` Martin K. Petersen
@ 2022-05-24 3:27 ` Martin K. Petersen
1 sibling, 0 replies; 3+ messages in thread
From: Martin K. Petersen @ 2022-05-24 3:27 UTC (permalink / raw)
To: Michael Reed, Colin Ian King, linux-scsi, James E . J . Bottomley
Cc: Martin K . Petersen, linux-kernel, kernel-janitors
On Wed, 18 May 2022 11:21:03 +0100, Colin Ian King wrote:
> Variable toke is being assigned a value that is never read. The variable
> is redundant, remove it.
>
> Cleans up clang scan build warning:
> warning: Although the value stored to 'toke' is used in the enclosing
> expression, the value is never actually read from 'toke'
> [deadcode.DeadStores]
>
> [...]
Applied to 5.19/scsi-queue, thanks!
[1/1] scsi: qla1280: remove redundant variable toke
https://git.kernel.org/mkp/scsi/c/c10ba0c961d3
--
Martin K. Petersen Oracle Linux Engineering
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-05-24 3:27 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-18 10:21 [PATCH] scsi: qla1280: remove redundant variable toke Colin Ian King
2022-05-20 0:26 ` Martin K. Petersen
2022-05-24 3:27 ` Martin K. Petersen
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.