* [PATCH] wl12xx: fix SDIO suspend/resume
@ 2011-11-08 13:56 Eyal Shapira
2011-11-08 14:14 ` Luciano Coelho
0 siblings, 1 reply; 2+ messages in thread
From: Eyal Shapira @ 2011-11-08 13:56 UTC (permalink / raw)
To: Luciano Coelho; +Cc: linux-wireless
wl1271_suspend/resume() accessed the wrong struct and not wl1271
which caused it to think that wow was enabled when it wasn't.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
---
drivers/net/wireless/wl12xx/sdio.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/net/wireless/wl12xx/sdio.c b/drivers/net/wireless/wl12xx/sdio.c
index ed97f9c..468a505 100644
--- a/drivers/net/wireless/wl12xx/sdio.c
+++ b/drivers/net/wireless/wl12xx/sdio.c
@@ -289,7 +289,8 @@ static int wl1271_suspend(struct device *dev)
/* Tell MMC/SDIO core it's OK to power down the card
* (if it isn't already), but not to remove it completely */
struct sdio_func *func = dev_to_sdio_func(dev);
- struct wl1271 *wl = sdio_get_drvdata(func);
+ struct wl12xx_sdio_glue *glue = sdio_get_drvdata(func);
+ struct wl1271 *wl = platform_get_drvdata(glue->core);
mmc_pm_flag_t sdio_flags;
int ret = 0;
@@ -324,7 +325,8 @@ out:
static int wl1271_resume(struct device *dev)
{
struct sdio_func *func = dev_to_sdio_func(dev);
- struct wl1271 *wl = sdio_get_drvdata(func);
+ struct wl12xx_sdio_glue *glue = sdio_get_drvdata(func);
+ struct wl1271 *wl = platform_get_drvdata(glue->core);
dev_dbg(dev, "wl1271 resume\n");
if (wl->wow_enabled) {
--
1.7.4.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-11-08 14:14 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-11-08 13:56 [PATCH] wl12xx: fix SDIO suspend/resume Eyal Shapira
2011-11-08 14:14 ` Luciano Coelho
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox