2009-10-09 04:20:38

by Sujith

[permalink] [raw]
Subject: [PATCH] ath9k: Fix TX hang poll routine

When TX is hung, the chip is reset. Ensure that
the chip is awake by using the PS wrappers.

Signed-off-by: Sujith <[email protected]>
---
drivers/net/wireless/ath/ath9k/xmit.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/net/wireless/ath/ath9k/xmit.c b/drivers/net/wireless/ath/ath9k/xmit.c
index a8620b1..2a4efcb 100644
--- a/drivers/net/wireless/ath/ath9k/xmit.c
+++ b/drivers/net/wireless/ath/ath9k/xmit.c
@@ -2079,7 +2079,9 @@ static void ath_tx_complete_poll_work(struct work_struct *work)
if (needreset) {
ath_print(ath9k_hw_common(sc->sc_ah), ATH_DBG_RESET,
"tx hung, resetting the chip\n");
+ ath9k_ps_wakeup(sc);
ath_reset(sc, false);
+ ath9k_ps_restore(sc);
}

ieee80211_queue_delayed_work(sc->hw, &sc->tx_complete_work,
--
1.6.4.4



2009-11-24 16:11:33

by Luis R. Rodriguez

[permalink] [raw]
Subject: Re: [PATCH] ath9k: Fix TX hang poll routine

On Thu, Oct 8, 2009 at 8:21 PM, Sujith <[email protected]> wrote:
> When TX is hung, the chip is reset. Ensure that
> the chip is awake by using the PS wrappers.
>
> Signed-off-by: Sujith <[email protected]>
> ---
>  drivers/net/wireless/ath/ath9k/xmit.c |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/ath9k/xmit.c b/drivers/net/wireless/ath/ath9k/xmit.c
> index a8620b1..2a4efcb 100644
> --- a/drivers/net/wireless/ath/ath9k/xmit.c
> +++ b/drivers/net/wireless/ath/ath9k/xmit.c
> @@ -2079,7 +2079,9 @@ static void ath_tx_complete_poll_work(struct work_struct *work)
>        if (needreset) {
>                ath_print(ath9k_hw_common(sc->sc_ah), ATH_DBG_RESET,
>                          "tx hung, resetting the chip\n");
> +               ath9k_ps_wakeup(sc);
>                ath_reset(sc, false);
> +               ath9k_ps_restore(sc);
>        }
>
>        ieee80211_queue_delayed_work(sc->hw, &sc->tx_complete_work,
> --

John this should be pulled to 2.6.32 if possible. It would do the
actual reset and fix TX properly if we are asleep.

Luis

2009-12-02 17:04:16

by Luis R. Rodriguez

[permalink] [raw]
Subject: Re: [PATCH] ath9k: Fix TX hang poll routine

On Tue, Nov 24, 2009 at 8:11 AM, Luis R. Rodriguez <[email protected]> wrote:
> On Thu, Oct 8, 2009 at 8:21 PM, Sujith <[email protected]> wrote:
>> When TX is hung, the chip is reset. Ensure that
>> the chip is awake by using the PS wrappers.
>>
>> Signed-off-by: Sujith <[email protected]>
>> ---
>>  drivers/net/wireless/ath/ath9k/xmit.c |    2 ++
>>  1 files changed, 2 insertions(+), 0 deletions(-)
>>
>> diff --git a/drivers/net/wireless/ath/ath9k/xmit.c b/drivers/net/wireless/ath/ath9k/xmit.c
>> index a8620b1..2a4efcb 100644
>> --- a/drivers/net/wireless/ath/ath9k/xmit.c
>> +++ b/drivers/net/wireless/ath/ath9k/xmit.c
>> @@ -2079,7 +2079,9 @@ static void ath_tx_complete_poll_work(struct work_struct *work)
>>        if (needreset) {
>>                ath_print(ath9k_hw_common(sc->sc_ah), ATH_DBG_RESET,
>>                          "tx hung, resetting the chip\n");
>> +               ath9k_ps_wakeup(sc);
>>                ath_reset(sc, false);
>> +               ath9k_ps_restore(sc);
>>        }
>>
>>        ieee80211_queue_delayed_work(sc->hw, &sc->tx_complete_work,
>> --
>
> John this should be pulled to 2.6.32 if possible. It would do the
> actual reset and fix TX properly if we are asleep.

Note: stable fix, don't recall yet if this will apply to 31 series though.

Luis