diff options
author | Phillip Potter <phil@philpotter.co.uk> | 2022-02-16 04:07:06 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2022-02-17 18:00:36 +0300 |
commit | fee26e2257c58b390b813f668a3982049e8d19ff (patch) | |
tree | d7f6cc14b3875ef19c499afe56fdaf6009d8500e /drivers/staging/r8188eu/core/rtw_pwrctrl.c | |
parent | db381acc41b43e03cbb2beb2abc89ba665d86a44 (diff) | |
download | linux-fee26e2257c58b390b813f668a3982049e8d19ff.tar.xz |
staging: r8188eu: fix lines modified by DBG_88E cleanup
A number of style problems were left behind by the DBG_88E cleanup:
(1) Empty if/else blocks.
(2) Parenthesised if/while statements containing only one line.
(3) Entire blocks which server zero purpose after removal of DBG_88E.
(4) Various warnings about whitespace, and constant comparison order.
(5) Use of __constant_htons instead when htons should be used.
Fix up these issues across the driver in any file touched by the
previous cleanup. Long line warnings will be addresses in a later
patch.
Signed-off-by: Phillip Potter <phil@philpotter.co.uk>
Link: https://lore.kernel.org/r/20220216010709.791-13-phil@philpotter.co.uk
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/r8188eu/core/rtw_pwrctrl.c')
-rw-r--r-- | drivers/staging/r8188eu/core/rtw_pwrctrl.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/drivers/staging/r8188eu/core/rtw_pwrctrl.c b/drivers/staging/r8188eu/core/rtw_pwrctrl.c index db7074bf5741..c7c79cd9e213 100644 --- a/drivers/staging/r8188eu/core/rtw_pwrctrl.c +++ b/drivers/staging/r8188eu/core/rtw_pwrctrl.c @@ -14,9 +14,8 @@ void ips_enter(struct adapter *padapter) struct xmit_priv *pxmit_priv = &padapter->xmitpriv; if (pxmit_priv->free_xmitbuf_cnt != NR_XMITBUFF || - pxmit_priv->free_xmit_extbuf_cnt != NR_XMIT_EXTBUFF) { + pxmit_priv->free_xmit_extbuf_cnt != NR_XMIT_EXTBUFF) return; - } mutex_lock(&pwrpriv->lock); @@ -172,9 +171,8 @@ static u8 PS_RDY_CHECK(struct adapter *padapter) return false; if (pwrpriv->bInSuspend) return false; - if (padapter->securitypriv.dot11AuthAlgrthm == dot11AuthAlgrthm_8021X && !padapter->securitypriv.binstallGrpkey) { + if (padapter->securitypriv.dot11AuthAlgrthm == dot11AuthAlgrthm_8021X && !padapter->securitypriv.binstallGrpkey) return false; - } return true; } @@ -367,10 +365,6 @@ int _rtw_pwr_wakeup(struct adapter *padapter, u32 ips_deffer_ms, const char *cal if (pwrpriv->ps_processing) { while (pwrpriv->ps_processing && rtw_get_passing_time_ms(start) <= 3000) msleep(10); - if (pwrpriv->ps_processing) - ; - else - ; } /* System suspend is not allowed to wakeup */ @@ -379,10 +373,6 @@ int _rtw_pwr_wakeup(struct adapter *padapter, u32 ips_deffer_ms, const char *cal (rtw_get_passing_time_ms(start) <= 3000 || (rtw_get_passing_time_ms(start) <= 500))) msleep(10); - if (pwrpriv->bInSuspend) - ; - else - ; } /* I think this should be check in IPS, LPS, autosuspend functions... */ |