Commit 85eba7ac authored by Philipp Hortmann's avatar Philipp Hortmann Committed by Greg Kroah-Hartman

staging: rtl8192e: Remove unchanged variable bFwCtrlLPS

bFwCtrlLPS is just once initialized and never changed. The evaluation will
always have the same result. Remove resulting dead code.
Signed-off-by: default avatarPhilipp Hortmann <philipp.g.hortmann@gmail.com>
Link: https://lore.kernel.org/r/d5b5cfd26648180d082f38085a807c932e87703c.1664616227.git.philipp.g.hortmann@gmail.comSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent febdb8ee
......@@ -889,7 +889,6 @@ static void _rtl92e_init_priv_variable(struct net_device *dev)
priv->rtllib->PowerSaveControl.bInactivePs = true;
priv->rtllib->PowerSaveControl.bIPSModeBackup = false;
priv->rtllib->PowerSaveControl.bLeisurePs = true;
priv->rtllib->PowerSaveControl.bFwCtrlLPS = false;
priv->rtllib->LPSDelayCnt = 0;
priv->rtllib->sta_sleep = LPS_IS_WAKE;
priv->rtllib->rf_power_state = rf_on;
......
......@@ -229,11 +229,8 @@ void rtl92e_leisure_ps_enter(struct net_device *dev)
if (pPSC->LpsIdleCount >= RT_CHECK_FOR_HANG_PERIOD) {
if (priv->rtllib->ps == RTLLIB_PS_DISABLED) {
if (!pPSC->bFwCtrlLPS) {
if (priv->rtllib->SetFwCmdHandler)
priv->rtllib->SetFwCmdHandler(
dev, FW_CMD_LPS_ENTER);
}
if (priv->rtllib->SetFwCmdHandler)
priv->rtllib->SetFwCmdHandler(dev, FW_CMD_LPS_ENTER);
_rtl92e_ps_set_mode(dev, RTLLIB_PS_MBCAST |
RTLLIB_PS_UNICAST);
}
......@@ -251,12 +248,8 @@ void rtl92e_leisure_ps_leave(struct net_device *dev)
if (pPSC->bLeisurePs) {
if (priv->rtllib->ps != RTLLIB_PS_DISABLED) {
_rtl92e_ps_set_mode(dev, RTLLIB_PS_DISABLED);
if (!pPSC->bFwCtrlLPS) {
if (priv->rtllib->SetFwCmdHandler)
priv->rtllib->SetFwCmdHandler(dev,
FW_CMD_LPS_LEAVE);
}
if (priv->rtllib->SetFwCmdHandler)
priv->rtllib->SetFwCmdHandler(dev, FW_CMD_LPS_LEAVE);
}
}
}
......@@ -1264,9 +1264,6 @@ struct rt_pwr_save_ctrl {
u32 CurPsLevel;
u32 RegRfPsLevel;
bool bFwCtrlLPS;
};
#define RT_RF_CHANGE_SOURCE u32
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment