diff options
author | Colin Ian King <colin.i.king@gmail.com> | 2021-12-05 22:59:01 +0000 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2021-12-06 22:22:18 -0500 |
commit | c27fd25db39b8f16aeda8563d4be6f33e59d07d1 (patch) | |
tree | 81b8a417a48e8903cda2a82fb33fd3d625cc0d05 | |
parent | 4c3e3f8cfc05116d1adf83d95322090f335d2091 (diff) | |
download | linux-c27fd25db39b8f16aeda8563d4be6f33e59d07d1.tar.gz linux-c27fd25db39b8f16aeda8563d4be6f33e59d07d1.tar.bz2 linux-c27fd25db39b8f16aeda8563d4be6f33e59d07d1.zip |
scsi: mptfusion: Remove redundant variable r
Variable r is being assigned a value that is never read. The assignment is
redundant and so is the variable, so remove these. Remove unnecessary the
{} braces in the if statement too.
Link: https://lore.kernel.org/r/20211205225901.54362-1-colin.i.king@gmail.com
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
-rw-r--r-- | drivers/message/fusion/mptbase.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/message/fusion/mptbase.c b/drivers/message/fusion/mptbase.c index b94d5e4fdc23..24a4532053e4 100644 --- a/drivers/message/fusion/mptbase.c +++ b/drivers/message/fusion/mptbase.c @@ -1274,8 +1274,6 @@ mpt_send_handshake_request(u8 cb_idx, MPT_ADAPTER *ioc, int reqBytes, u32 *req, static int mpt_host_page_access_control(MPT_ADAPTER *ioc, u8 access_control_value, int sleepFlag) { - int r = 0; - /* return if in use */ if (CHIPREG_READ32(&ioc->chip->Doorbell) & MPI_DOORBELL_ACTIVE) @@ -1289,9 +1287,9 @@ mpt_host_page_access_control(MPT_ADAPTER *ioc, u8 access_control_value, int slee (access_control_value<<12))); /* Wait for IOC to clear Doorbell Status bit */ - if ((r = WaitForDoorbellAck(ioc, 5, sleepFlag)) < 0) { + if (WaitForDoorbellAck(ioc, 5, sleepFlag) < 0) return -2; - }else + else return 0; } |