[PATCH 2/8] staging: r8188eu: don't set _SUCCESS again

From: Martin Kaiser
Date: Sat Apr 09 2022 - 11:16:15 EST


ret is initialized to _SUCCESS, there's no need to set it again.

Signed-off-by: Martin Kaiser <martin@xxxxxxxxx>
---
drivers/staging/r8188eu/core/rtw_pwrctrl.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/staging/r8188eu/core/rtw_pwrctrl.c b/drivers/staging/r8188eu/core/rtw_pwrctrl.c
index 7c1e79808087..c43759500ef9 100644
--- a/drivers/staging/r8188eu/core/rtw_pwrctrl.c
+++ b/drivers/staging/r8188eu/core/rtw_pwrctrl.c
@@ -382,10 +382,9 @@ int rtw_pwr_wakeup(struct adapter *padapter)
msleep(10);

/* I think this should be check in IPS, LPS, autosuspend functions... */
- if (check_fwstate(pmlmepriv, _FW_LINKED)) {
- ret = _SUCCESS;
+ if (check_fwstate(pmlmepriv, _FW_LINKED))
goto exit;
- }
+
if (rf_off == pwrpriv->rf_pwrstate) {
if (_FAIL == ips_leave(padapter)) {
ret = _FAIL;
--
2.30.2