diff options
author | Dmitry Antipov <dmantipov@yandex.ru> | 2023-10-13 15:45:31 +0300 |
---|---|---|
committer | Kalle Valo <kvalo@kernel.org> | 2023-10-19 10:27:28 +0300 |
commit | 9a66e73094add3d5f330db83982aa20591189fcc (patch) | |
tree | 9efb9688e7c794f9a6aed41ce69305abe7250936 /drivers/net/wireless/realtek/rtlwifi/ps.c | |
parent | a86a8ca798e9c3037c04011c993a92c173fba0c2 (diff) | |
download | linux-9a66e73094add3d5f330db83982aa20591189fcc.tar.xz |
wifi: rtlwifi: cleanup struct rtl_ps_ctl
Remove set but otherwise unused 'sleep_ms', 'last_action', 'state'
and 'last_slept' members of 'struct rtl_ps_ctl' (these seems to be
a leftovers from some older code) and adjust 'rtl_swlps_wq_callback()'
accordingly. Compile tested only.
Signed-off-by: Dmitry Antipov <dmantipov@yandex.ru>
Acked-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20231013124534.19714-1-dmantipov@yandex.ru
Diffstat (limited to 'drivers/net/wireless/realtek/rtlwifi/ps.c')
-rw-r--r-- | drivers/net/wireless/realtek/rtlwifi/ps.c | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/drivers/net/wireless/realtek/rtlwifi/ps.c b/drivers/net/wireless/realtek/rtlwifi/ps.c index 629c03271bde..6241e4fed4f6 100644 --- a/drivers/net/wireless/realtek/rtlwifi/ps.c +++ b/drivers/net/wireless/realtek/rtlwifi/ps.c @@ -681,25 +681,10 @@ void rtl_swlps_wq_callback(struct work_struct *work) ps_work.work); struct ieee80211_hw *hw = rtlworks->hw; struct rtl_priv *rtlpriv = rtl_priv(hw); - bool ps = false; - - ps = (hw->conf.flags & IEEE80211_CONF_PS); /* we can sleep after ps null send ok */ - if (rtlpriv->psc.state_inap) { + if (rtlpriv->psc.state_inap) rtl_swlps_rf_sleep(hw); - - if (rtlpriv->psc.state && !ps) { - rtlpriv->psc.sleep_ms = jiffies_to_msecs(jiffies - - rtlpriv->psc.last_action); - } - - if (ps) - rtlpriv->psc.last_slept = jiffies; - - rtlpriv->psc.last_action = jiffies; - rtlpriv->psc.state = ps; - } } static void rtl_p2p_noa_ie(struct ieee80211_hw *hw, void *data, |