ath6kl: Recover from "wmi ctrl ep is full" condition
authorVasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Wed, 29 Aug 2012 14:10:28 +0000 (19:40 +0530)
committerKalle Valo <kvalo@qca.qualcomm.com>
Wed, 24 Oct 2012 08:49:49 +0000 (11:49 +0300)
In some error conditions, fw pauses HTC pipes which would
result in control endpoint full condition. When we hit this
case, most of the time the device will be unusable. Re-initialize
the target to recover from this situation.

Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
drivers/net/wireless/ath/ath6kl/core.h
drivers/net/wireless/ath/ath6kl/recovery.c
drivers/net/wireless/ath/ath6kl/txrx.c

index b2cbecf6cfe5bf8afeb0dd51fd48f2b86ccf810f..ac90b31514bdd806a340dc9fb80955c006d4f979 100644 (file)
@@ -660,6 +660,7 @@ enum ath6kl_state {
 enum ath6kl_fw_err {
        ATH6KL_FW_ASSERT,
        ATH6KL_FW_HB_RESP_FAILURE,
+       ATH6KL_FW_EP_FULL,
 };
 
 struct ath6kl {
index 4e3f205bb8a096f61a6986ca965949b5de744d4e..03edeb8c2ce3161b5ce451b5be0e500f7028444e 100644 (file)
@@ -30,6 +30,8 @@ static void ath6kl_recovery_work(struct work_struct *work)
        ath6kl_init_hw_restart(ar);
 
        ar->state = ATH6KL_STATE_ON;
+       clear_bit(WMI_CTRL_EP_FULL, &ar->flag);
+
        ar->fw_recovery.err_reason = 0;
 
        if (ar->fw_recovery.enable)
index cbe1a9d891123119e7591d875f280e99801a186d..e867193373fe25fcd4e20a499c24b436ad744cd8 100644 (file)
@@ -594,6 +594,7 @@ enum htc_send_full_action ath6kl_tx_queue_full(struct htc_target *target,
                 */
                set_bit(WMI_CTRL_EP_FULL, &ar->flag);
                ath6kl_err("wmi ctrl ep is full\n");
+               ath6kl_recovery_err_notify(ar, ATH6KL_FW_EP_FULL);
                return action;
        }