[PATCH 1/8] staging: r8188eu: simplify delay conditions in rtw_pwr_wakeup
From: Martin Kaiser
Date: Sat Apr 09 2022 - 11:16:25 EST
Simplify the conditions for a loop in rtw_pwr_wakeup that waits while
the system is suspended.
Signed-off-by: Martin Kaiser <martin@xxxxxxxxx>
---
drivers/staging/r8188eu/core/rtw_pwrctrl.c | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/drivers/staging/r8188eu/core/rtw_pwrctrl.c b/drivers/staging/r8188eu/core/rtw_pwrctrl.c
index efdc7de49d49..7c1e79808087 100644
--- a/drivers/staging/r8188eu/core/rtw_pwrctrl.c
+++ b/drivers/staging/r8188eu/core/rtw_pwrctrl.c
@@ -378,12 +378,8 @@ int rtw_pwr_wakeup(struct adapter *padapter)
}
/* System suspend is not allowed to wakeup */
- if (pwrpriv->bInSuspend) {
- while (pwrpriv->bInSuspend &&
- (rtw_get_passing_time_ms(start) <= 3000 ||
- (rtw_get_passing_time_ms(start) <= 500)))
- msleep(10);
- }
+ while (pwrpriv->bInSuspend && rtw_get_passing_time_ms(start) <= 3000)
+ msleep(10);
/* I think this should be check in IPS, LPS, autosuspend functions... */
if (check_fwstate(pmlmepriv, _FW_LINKED)) {
--
2.30.2