aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEliad Peller <eliad@wizery.com>2010-10-27 08:09:57 -0400
committerJohn W. Linville <linville@tuxdriver.com>2010-11-15 13:25:24 -0500
commitccc83b046c03378bbaf7cf095d8d7e9b9abb24c5 (patch)
tree13fc439ebd636c56f17e8094c5e4359c41e34ca7
parent03107a4b5923aa7767329e857caf227749087e47 (diff)
wl1271: handle HW watchdog interrupt
unmask the WL1271_ACX_INTR_WATCHDOG interrupt. when getting it - enqueue a recovery work and bail out. Signed-off-by: Eliad Peller <eliad@wizery.com> Reviewed-by: Luciano Coelho <luciano.coelho@nokia.com> Signed-off-by: Luciano Coelho <luciano.coelho@nokia.com>
-rw-r--r--drivers/net/wireless/wl12xx/wl1271_acx.h3
-rw-r--r--drivers/net/wireless/wl12xx/wl1271_main.c9
2 files changed, 11 insertions, 1 deletions
diff --git a/drivers/net/wireless/wl12xx/wl1271_acx.h b/drivers/net/wireless/wl12xx/wl1271_acx.h
index 758916760912..b7c490845f3e 100644
--- a/drivers/net/wireless/wl12xx/wl1271_acx.h
+++ b/drivers/net/wireless/wl12xx/wl1271_acx.h
@@ -61,7 +61,8 @@
61 WL1271_ACX_INTR_HW_AVAILABLE | \ 61 WL1271_ACX_INTR_HW_AVAILABLE | \
62 WL1271_ACX_INTR_DATA) 62 WL1271_ACX_INTR_DATA)
63 63
64#define WL1271_INTR_MASK (WL1271_ACX_INTR_EVENT_A | \ 64#define WL1271_INTR_MASK (WL1271_ACX_INTR_WATCHDOG | \
65 WL1271_ACX_INTR_EVENT_A | \
65 WL1271_ACX_INTR_EVENT_B | \ 66 WL1271_ACX_INTR_EVENT_B | \
66 WL1271_ACX_INTR_HW_AVAILABLE | \ 67 WL1271_ACX_INTR_HW_AVAILABLE | \
67 WL1271_ACX_INTR_DATA) 68 WL1271_ACX_INTR_DATA)
diff --git a/drivers/net/wireless/wl12xx/wl1271_main.c b/drivers/net/wireless/wl12xx/wl1271_main.c
index a3a1ebc578a3..f5b1d19bc88d 100644
--- a/drivers/net/wireless/wl12xx/wl1271_main.c
+++ b/drivers/net/wireless/wl12xx/wl1271_main.c
@@ -529,6 +529,15 @@ static void wl1271_irq_work(struct work_struct *work)
529 529
530 intr &= WL1271_INTR_MASK; 530 intr &= WL1271_INTR_MASK;
531 531
532 if (unlikely(intr & WL1271_ACX_INTR_WATCHDOG)) {
533 wl1271_error("watchdog interrupt received! "
534 "starting recovery.");
535 ieee80211_queue_work(wl->hw, &wl->recovery_work);
536
537 /* restarting the chip. ignore any other interrupt. */
538 goto out;
539 }
540
532 if (intr & WL1271_ACX_INTR_DATA) { 541 if (intr & WL1271_ACX_INTR_DATA) {
533 wl1271_debug(DEBUG_IRQ, "WL1271_ACX_INTR_DATA"); 542 wl1271_debug(DEBUG_IRQ, "WL1271_ACX_INTR_DATA");
534 543