[PATCH 3/8] staging: r8188eu: make return values consistent
From: Martin Kaiser
Date: Sat Apr 09 2022 - 11:16:28 EST
rtw_pwr_wakeup should return _SUCCESS or _FAIL.
Replace false with _FAIL in one place and reformat the if-statement.
Signed-off-by: Martin Kaiser <martin@xxxxxxxxx>
---
drivers/staging/r8188eu/core/rtw_pwrctrl.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/staging/r8188eu/core/rtw_pwrctrl.c b/drivers/staging/r8188eu/core/rtw_pwrctrl.c
index c43759500ef9..a7471468e2e2 100644
--- a/drivers/staging/r8188eu/core/rtw_pwrctrl.c
+++ b/drivers/staging/r8188eu/core/rtw_pwrctrl.c
@@ -392,10 +392,8 @@ int rtw_pwr_wakeup(struct adapter *padapter)
}
}
- /* TODO: the following checking need to be merged... */
- if (padapter->bDriverStopped || !padapter->bup ||
- !padapter->hw_init_completed) {
- ret = false;
+ if (padapter->bDriverStopped || !padapter->bup || !padapter->hw_init_completed) {
+ ret = _FAIL;
goto exit;
}
--
2.30.2