mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-13 00:00:00 -04:00
staging: rtl8723au: Clean up rtw_pm_set_ips23a()
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
48d5bb4403
commit
c742e339d5
2 changed files with 6 additions and 15 deletions
|
|
@ -615,19 +615,16 @@ int rtw_pm_set_ips23a(struct rtw_adapter *padapter, u8 mode)
|
|||
{
|
||||
struct pwrctrl_priv *pwrctrlpriv = &padapter->pwrctrlpriv;
|
||||
|
||||
if (mode == IPS_NORMAL || mode == IPS_LEVEL_2) {
|
||||
rtw_ips_mode_req(pwrctrlpriv, mode);
|
||||
DBG_8723A("%s %s\n", __func__,
|
||||
mode == IPS_NORMAL?"IPS_NORMAL":"IPS_LEVEL_2");
|
||||
return 0;
|
||||
} else if (mode == IPS_NONE) {
|
||||
rtw_ips_mode_req(pwrctrlpriv, mode);
|
||||
if (mode != IPS_NORMAL && mode != IPS_LEVEL_2 && mode != IPS_NONE)
|
||||
return -EINVAL;
|
||||
|
||||
pwrctrlpriv->ips_mode_req = mode;
|
||||
if (mode == IPS_NONE) {
|
||||
DBG_8723A("%s %s\n", __func__, "IPS_NONE");
|
||||
if (padapter->bSurpriseRemoved == 0 &&
|
||||
rtw_pwr_wakeup(padapter) == _FAIL)
|
||||
return -EFAULT;
|
||||
} else
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -214,12 +214,6 @@ struct pwrctrl_priv {
|
|||
unsigned long PS_BBRegBackup[PSBBREG_TOTALCNT];
|
||||
};
|
||||
|
||||
#define rtw_get_ips_mode_req(pwrctrlpriv) \
|
||||
((pwrctrlpriv)->ips_mode_req)
|
||||
|
||||
#define rtw_ips_mode_req(pwrctrlpriv, ips_mode) \
|
||||
((pwrctrlpriv)->ips_mode_req = (ips_mode))
|
||||
|
||||
#define RTW_PWR_STATE_CHK_INTERVAL 2000
|
||||
|
||||
#define _rtw_set_pwr_state_check_timer(pwrctrlpriv, ms) \
|
||||
|
|
|
|||
Loading…
Reference in a new issue