[lvc-project] [PATCH] wifi: mwifiex: fix SDIO firmware dump wait
Dmitry Antipov
dmantipov at yandex.ru
Wed Sep 20 14:22:32 MSK 2023
In 'mwifiex_sdio_generic_fw_dump()', move (presumably placed
by mistake) 'if (tries == MAX_POLL_TRIES)' check to an outer
waiting loop.
Found by Linux Verification Center (linuxtesting.org) with SVACE.
Signed-off-by: Dmitry Antipov <dmantipov at yandex.ru>
---
drivers/net/wireless/marvell/mwifiex/sdio.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/drivers/net/wireless/marvell/mwifiex/sdio.c b/drivers/net/wireless/marvell/mwifiex/sdio.c
index 774858cfe86f..98f16eb8f298 100644
--- a/drivers/net/wireless/marvell/mwifiex/sdio.c
+++ b/drivers/net/wireless/marvell/mwifiex/sdio.c
@@ -2899,12 +2899,12 @@ static void mwifiex_sdio_generic_fw_dump(struct mwifiex_adapter *adapter)
}
if (start_flag == 0)
break;
- if (tries == MAX_POLL_TRIES) {
- mwifiex_dbg(adapter, ERROR,
- "FW not ready to dump\n");
- ret = -1;
- goto done;
- }
+ }
+ if (tries == MAX_POLL_TRIES) {
+ mwifiex_dbg(adapter, ERROR,
+ "FW not ready to dump\n");
+ ret = -1;
+ goto done;
}
usleep_range(100, 200);
}
--
2.41.0
More information about the lvc-project
mailing list