Skip to content

Commit 6d4bb3f

Browse files
kitakar5525qzed
authored andcommitted
mwifiex: sta_cmd: do not enable auto_ds by default
(made based on commit https://github.com/sebanc/linux-kernel/commit/5cd03f3e1c01440d0e0bd0cd00a51732c07f99da) According to the commit this commit is based on, enabling "auto deep sleep" (auto_ds) causes "suspend/resume fails when not connected to an Access Point.". This commit stops enabling auto_ds on driver initialization to fix the issue. Signed-off-by: Tsuchiya Yuto (kitakar5525) <kitakar@gmail.com> (cherry picked from commit cecd107 from PR #44) Signed-off-by: Tsuchiya Yuto (kitakar5525) <kitakar@gmail.com>
1 parent 1aaf13f commit 6d4bb3f

File tree

1 file changed

+4
-13
lines changed
  • drivers/net/wireless/marvell/mwifiex

1 file changed

+4
-13
lines changed

drivers/net/wireless/marvell/mwifiex/sta_cmd.c

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2254,7 +2254,6 @@ int mwifiex_sta_prepare_cmd(struct mwifiex_private *priv, uint16_t cmd_no,
22542254
* - Function init (for first interface only)
22552255
* - Read MAC address (for first interface only)
22562256
* - Reconfigure Tx buffer size (for first interface only)
2257-
* - Enable auto deep sleep (for first interface only)
22582257
* - Get Tx rate
22592258
* - Get Tx power
22602259
* - Set IBSS coalescing status
@@ -2267,7 +2266,6 @@ int mwifiex_sta_init_cmd(struct mwifiex_private *priv, u8 first_sta, bool init)
22672266
struct mwifiex_adapter *adapter = priv->adapter;
22682267
int ret;
22692268
struct mwifiex_ds_11n_amsdu_aggr_ctrl amsdu_aggr_ctrl;
2270-
struct mwifiex_ds_auto_ds auto_ds;
22712269
enum state_11d_t state_11d;
22722270
struct mwifiex_ds_11n_tx_cfg tx_cfg;
22732271
u8 sdio_sp_rx_aggr_enable;
@@ -2384,17 +2382,10 @@ int mwifiex_sta_init_cmd(struct mwifiex_private *priv, u8 first_sta, bool init)
23842382
if (ret)
23852383
return -1;
23862384

2387-
if (!disable_auto_ds && first_sta &&
2388-
priv->bss_type != MWIFIEX_BSS_TYPE_UAP) {
2389-
/* Enable auto deep sleep */
2390-
auto_ds.auto_ds = DEEP_SLEEP_ON;
2391-
auto_ds.idle_time = DEEP_SLEEP_IDLE_TIME;
2392-
ret = mwifiex_send_cmd(priv, HostCmd_CMD_802_11_PS_MODE_ENH,
2393-
EN_AUTO_PS, BITMAP_AUTO_DS,
2394-
&auto_ds, true);
2395-
if (ret)
2396-
return -1;
2397-
}
2385+
/* Not enabling auto deep sleep (auto_ds) by default. Enabling
2386+
* this reportedly causes "suspend/resume fails when not connected
2387+
* to an Access Point." Therefore, the relevant code was removed
2388+
* from here. */
23982389

23992390
if (priv->bss_type != MWIFIEX_BSS_TYPE_UAP) {
24002391
/* Send cmd to FW to enable/disable 11D function */

0 commit comments

Comments
 (0)