summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/mwifiex/sdio.c
diff options
context:
space:
mode:
authorAmitkumar Karwar <akarwar@marvell.com>2014-03-26 06:01:20 +0400
committerJohn W. Linville <linville@tuxdriver.com>2014-03-27 22:20:06 +0400
commitc0dbba6688b0acd582b7d6d59574fdf50f950981 (patch)
treec58f3e399f7fbc522acbb5aba7aae40a6caa79fe /drivers/net/wireless/mwifiex/sdio.c
parentb49f639f841cf19cc7a8737c836210d4fa0baa76 (diff)
downloadlinux-c0dbba6688b0acd582b7d6d59574fdf50f950981.tar.xz
mwifiex: cancel pending commands during host sleep
Sometimes we may end up downloading other commands when host sleep is configured. This patch makes sure that pending commands are cancelled and we stop queueing further commands during host sleep. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/mwifiex/sdio.c')
-rw-r--r--drivers/net/wireless/mwifiex/sdio.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/wireless/mwifiex/sdio.c b/drivers/net/wireless/mwifiex/sdio.c
index e0dcd3ed7a69..d206f04d4994 100644
--- a/drivers/net/wireless/mwifiex/sdio.c
+++ b/drivers/net/wireless/mwifiex/sdio.c
@@ -237,6 +237,7 @@ static int mwifiex_sdio_suspend(struct device *dev)
/* Enable the Host Sleep */
if (!mwifiex_enable_hs(adapter)) {
dev_err(adapter->dev, "cmd: failed to suspend\n");
+ adapter->hs_enabling = false;
return -EFAULT;
}
@@ -245,6 +246,7 @@ static int mwifiex_sdio_suspend(struct device *dev)
/* Indicate device suspended */
adapter->is_suspended = true;
+ adapter->hs_enabling = false;
return ret;
}