summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath/ath6kl/recovery.c
diff options
context:
space:
mode:
authorVasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>2012-09-03 11:19:37 +0400
committerKalle Valo <kvalo@qca.qualcomm.com>2012-10-24 12:49:49 +0400
commit66ddcc39420f3c6d2356f7618fbed3dd61177cee (patch)
tree17150794564db7d83ebecc5ad494f762ca270b41 /drivers/net/wireless/ath/ath6kl/recovery.c
parenta3561706320380027d4ac087e7b92ca19c0150df (diff)
downloadlinux-66ddcc39420f3c6d2356f7618fbed3dd61177cee.tar.xz
ath6kl: Make fw error recovery configurable
Add a modparam to configure recovery. Recovery from firmware error is disabled by default to debug the actual issue further. To recovery from error, modprobe ath6kl_core recovery_enable=1. Reported-by: Jin Navy <nhjin@qca.qualcomm.com> Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath6kl/recovery.c')
-rw-r--r--drivers/net/wireless/ath/ath6kl/recovery.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath6kl/recovery.c b/drivers/net/wireless/ath/ath6kl/recovery.c
index 98b6aa09e1bf..3a8d5e97dc8e 100644
--- a/drivers/net/wireless/ath/ath6kl/recovery.c
+++ b/drivers/net/wireless/ath/ath6kl/recovery.c
@@ -41,6 +41,9 @@ static void ath6kl_recovery_work(struct work_struct *work)
void ath6kl_recovery_err_notify(struct ath6kl *ar, enum ath6kl_fw_err reason)
{
+ if (!ar->fw_recovery.enable)
+ return;
+
ath6kl_dbg(ATH6KL_DBG_RECOVERY, "Fw error detected, reason:%d\n",
reason);
@@ -112,6 +115,9 @@ void ath6kl_recovery_init(struct ath6kl *ar)
void ath6kl_recovery_cleanup(struct ath6kl *ar)
{
+ if (!ar->fw_recovery.enable)
+ return;
+
set_bit(RECOVERY_CLEANUP, &ar->flag);
del_timer_sync(&ar->fw_recovery.hb_timer);
@@ -120,6 +126,9 @@ void ath6kl_recovery_cleanup(struct ath6kl *ar)
void ath6kl_recovery_suspend(struct ath6kl *ar)
{
+ if (!ar->fw_recovery.enable)
+ return;
+
ath6kl_recovery_cleanup(ar);
if (!ar->fw_recovery.err_reason)
@@ -135,6 +144,9 @@ void ath6kl_recovery_suspend(struct ath6kl *ar)
void ath6kl_recovery_resume(struct ath6kl *ar)
{
+ if (!ar->fw_recovery.enable)
+ return;
+
clear_bit(RECOVERY_CLEANUP, &ar->flag);
if (!ar->fw_recovery.hb_poll)