[RFC PATCH 13/13] scsi: mpt3sas: comment about invalid usage of the list iterator

From: Jakob Koschel
Date: Thu Feb 17 2022 - 13:51:06 EST


Since the list iteration never exists early, reply_q is guaranteed to
be an invalid variable and should not be used within
_base_process_reply_queue(). Since I'm not sure what this code was
supposed to do, I just marked this with this comment.

Signed-off-by: Jakob Koschel <jakobkoschel@xxxxxxxxx>
---
drivers/scsi/mpt3sas/mpt3sas_base.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/scsi/mpt3sas/mpt3sas_base.c b/drivers/scsi/mpt3sas/mpt3sas_base.c
index 511726f92d9a..a6746e124226 100644
--- a/drivers/scsi/mpt3sas/mpt3sas_base.c
+++ b/drivers/scsi/mpt3sas/mpt3sas_base.c
@@ -2013,7 +2013,7 @@ mpt3sas_base_sync_reply_irqs(struct MPT3SAS_ADAPTER *ioc, u8 poll)
}
}
if (poll)
- _base_process_reply_queue(reply_q);
+ _base_process_reply_queue(reply_q); // COMMENT
}

/**
--
2.25.1