提交 b7be1522 编写于 作者: B Bing Zhao 提交者: John W. Linville

mwifiex: fix PCIe hs_cfg cancel cmd timeout

For pcie8897, the hs_cfg cancel command (0xe5) times out when host
comes out of suspend. This is caused by an incompleted host sleep
handshake between driver and firmware.

Like SDIO interface, PCIe also needs to go through firmware power
save events to complete the handshake for host sleep configuration.
Only USB interface doesn't require power save events for hs_cfg.

Cc: <stable@vger.kernel.org> # 3.10+
Signed-off-by: NBing Zhao <bzhao@marvell.com>
Signed-off-by: NAmitkumar Karwar <akarwar@marvell.com>
Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
上级 60ce314d
...@@ -1155,7 +1155,7 @@ int mwifiex_ret_802_11_hs_cfg(struct mwifiex_private *priv, ...@@ -1155,7 +1155,7 @@ int mwifiex_ret_802_11_hs_cfg(struct mwifiex_private *priv,
uint32_t conditions = le32_to_cpu(phs_cfg->params.hs_config.conditions); uint32_t conditions = le32_to_cpu(phs_cfg->params.hs_config.conditions);
if (phs_cfg->action == cpu_to_le16(HS_ACTIVATE) && if (phs_cfg->action == cpu_to_le16(HS_ACTIVATE) &&
adapter->iface_type == MWIFIEX_SDIO) { adapter->iface_type != MWIFIEX_USB) {
mwifiex_hs_activated_event(priv, true); mwifiex_hs_activated_event(priv, true);
return 0; return 0;
} else { } else {
...@@ -1167,8 +1167,7 @@ int mwifiex_ret_802_11_hs_cfg(struct mwifiex_private *priv, ...@@ -1167,8 +1167,7 @@ int mwifiex_ret_802_11_hs_cfg(struct mwifiex_private *priv,
} }
if (conditions != HS_CFG_CANCEL) { if (conditions != HS_CFG_CANCEL) {
adapter->is_hs_configured = true; adapter->is_hs_configured = true;
if (adapter->iface_type == MWIFIEX_USB || if (adapter->iface_type == MWIFIEX_USB)
adapter->iface_type == MWIFIEX_PCIE)
mwifiex_hs_activated_event(priv, true); mwifiex_hs_activated_event(priv, true);
} else { } else {
adapter->is_hs_configured = false; adapter->is_hs_configured = false;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册