From: Sharvari Harisangam <sharvari@xxxxxxxxxxx> mwifiex_queue_tx_pkt would queue the TX packet to driver queues and before return, would invoke main_work, which in turn would download the packet to firmware. In case the card is in sleep state, driver would wakeup the card(via interface). During resume it is possible that, the applications send packets even before interface has completed its resume. If driver try to access interface register(to wakeup the card), it would lead to invalid results. To avoid this, don't invoke main_work, when hs_activated is set. Signed-off-by: Sharvari Harisangam <sharvari@xxxxxxxxxxx> Signed-off-by: Ganapathi Bhat <gbhat@xxxxxxxxxxx> --- drivers/net/wireless/marvell/mwifiex/main.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/net/wireless/marvell/mwifiex/main.c b/drivers/net/wireless/marvell/mwifiex/main.c index a9657ae..7b5cf2c0 100644 --- a/drivers/net/wireless/marvell/mwifiex/main.c +++ b/drivers/net/wireless/marvell/mwifiex/main.c @@ -808,6 +808,11 @@ int mwifiex_queue_tx_pkt(struct mwifiex_private *priv, struct sk_buff *skb) mwifiex_wmm_add_buf_txqueue(priv, skb); } + if (priv->adapter->hs_activated) { + mwifiex_dbg(priv->adapter, ERROR, "hs_activated: queue TX\n"); + return 0; + } + mwifiex_queue_main_work(priv->adapter); return 0; -- 1.9.1