mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH][next] scsi: megaraid: remove redundant assignment to variable retval
@ 2024-01-18 12:14 Colin Ian King
  2024-01-24  2:38 ` Martin K. Petersen
  2024-01-30  2:26 ` Martin K. Petersen
  0 siblings, 2 replies; 3+ messages in thread
From: Colin Ian King @ 2024-01-18 12:14 UTC (permalink / raw)
  To: Kashyap Desai, Sumit Saxena, Shivasharan S, Chandrakanth patil,
	James E . J . Bottomley, Martin K . Petersen, megaraidlinux.pdl,
	linux-scsi
  Cc: kernel-janitors, linux-kernel

The variable retval is being assigned a value that is not being
read afterwards. The assignment is redundant and can be removed.

Cleans up clang scan warning:
Although the value stored to 'retval' is used in the enclosing
expression, the value is never actually read from 'retval'
[deadcode.DeadStores]

Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
---
 drivers/scsi/megaraid.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/scsi/megaraid.c b/drivers/scsi/megaraid.c
index 66a30a3e6cd5..38976f94453e 100644
--- a/drivers/scsi/megaraid.c
+++ b/drivers/scsi/megaraid.c
@@ -219,7 +219,7 @@ mega_query_adapter(adapter_t *adapter)
 	raw_mbox[3] = ENQ3_GET_SOLICITED_FULL;	/* i.e. 0x02 */
 
 	/* Issue a blocking command to the card */
-	if ((retval = issue_scb_block(adapter, raw_mbox))) {
+	if (issue_scb_block(adapter, raw_mbox)) {
 		/* the adapter does not support 40ld */
 
 		mraid_ext_inquiry	*ext_inq;
-- 
2.39.2


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-01-30  2:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-01-18 12:14 [PATCH][next] scsi: megaraid: remove redundant assignment to variable retval Colin Ian King
2024-01-24  2:38 ` Martin K. Petersen
2024-01-30  2:26 ` Martin K. Petersen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®