aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/wl12xx/wl1251.c
diff options
context:
space:
mode:
authorKalle Valo <kalle.valo@nokia.com>2009-06-12 07:16:32 -0400
committerJohn W. Linville <linville@tuxdriver.com>2009-07-10 14:57:47 -0400
commitc5483b71936333ba9474f57d0f3a7a7abf9b87a0 (patch)
tree599a485034698c38a2071528a0c57f5f547d152a /drivers/net/wireless/wl12xx/wl1251.c
parent01d9cfbdaadc64a46b57437c989bbad241074135 (diff)
wl12xx: check if elp wakeup failed
Check the return call from wl12xx_ps_elp_wakeup() and bail out if it fails. This shouldn't happen, but if does there's a fundamental low level issue. Signed-off-by: Kalle Valo <kalle.valo@nokia.com> Reviewed-by: Luciano Coelho <luciano.coelho@nokia.com> Reviewed-by: Vidhya Govindan <vidhya.govindan@nokia.com> Signed-off-by: Luciano Coelho <luciano.coelho@nokia.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/wl12xx/wl1251.c')
-rw-r--r--drivers/net/wireless/wl12xx/wl1251.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/net/wireless/wl12xx/wl1251.c b/drivers/net/wireless/wl12xx/wl1251.c
index 903624a540a3..5f6e75c61128 100644
--- a/drivers/net/wireless/wl12xx/wl1251.c
+++ b/drivers/net/wireless/wl12xx/wl1251.c
@@ -401,6 +401,7 @@ static void wl1251_irq_work(struct work_struct *work)
401 u32 intr; 401 u32 intr;
402 struct wl12xx *wl = 402 struct wl12xx *wl =
403 container_of(work, struct wl12xx, irq_work); 403 container_of(work, struct wl12xx, irq_work);
404 int ret;
404 405
405 mutex_lock(&wl->mutex); 406 mutex_lock(&wl->mutex);
406 407
@@ -409,7 +410,9 @@ static void wl1251_irq_work(struct work_struct *work)
409 if (wl->state == WL12XX_STATE_OFF) 410 if (wl->state == WL12XX_STATE_OFF)
410 goto out; 411 goto out;
411 412
412 wl12xx_ps_elp_wakeup(wl); 413 ret = wl12xx_ps_elp_wakeup(wl);
414 if (ret < 0)
415 goto out;
413 416
414 wl12xx_reg_write32(wl, ACX_REG_INTERRUPT_MASK, WL1251_ACX_INTR_ALL); 417 wl12xx_reg_write32(wl, ACX_REG_INTERRUPT_MASK, WL1251_ACX_INTR_ALL);
415 418
@@ -489,6 +492,7 @@ static void wl1251_irq_work(struct work_struct *work)
489 492
490out_sleep: 493out_sleep:
491 wl12xx_ps_elp_sleep(wl); 494 wl12xx_ps_elp_sleep(wl);
495
492out: 496out:
493 mutex_unlock(&wl->mutex); 497 mutex_unlock(&wl->mutex);
494} 498}