All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop
@ 2011-01-25  4:31 Bob Copeland
  2011-01-25  4:31 ` [PATCH 2/2] ath5k: correct endianness of frame duration Bob Copeland
                   ` (3 more replies)
  0 siblings, 4 replies; 14+ messages in thread
From: Bob Copeland @ 2011-01-25  4:31 UTC (permalink / raw)
  To: linville
  Cc: linux-wireless, mickflemm, Bruno Randolf, jirislaby, lrodriguez,
	Bob Copeland

Review spotted a problem with the error handling in ath5k_hw_dma_stop:
a successful return from ath5k_hw_stop_tx_dma will be treated as
an error, so we always bail out of the loop after processing a single
active queue.  As a result, we may not actually stop some queues during
reset.

Signed-off-by: Bob Copeland <me@bobcopeland.com>
---
These two patches fix some buglets I found when reviewing some old code.

 drivers/net/wireless/ath/ath5k/dma.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/wireless/ath/ath5k/dma.c b/drivers/net/wireless/ath/ath5k/dma.c
index 0064be7..e828b98 100644
--- a/drivers/net/wireless/ath/ath5k/dma.c
+++ b/drivers/net/wireless/ath/ath5k/dma.c
@@ -838,7 +838,7 @@ int ath5k_hw_dma_stop(struct ath5k_hw *ah)
 	for (i = 0; i < qmax; i++) {
 		err = ath5k_hw_stop_tx_dma(ah, i);
 		/* -EINVAL -> queue inactive */
-		if (err != -EINVAL)
+		if (err && err != -EINVAL)
 			return err;
 	}
 
-- 
1.7.1.1



^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH 2/2] ath5k: correct endianness of frame duration
  2011-01-25  4:31 [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop Bob Copeland
@ 2011-01-25  4:31 ` Bob Copeland
  2011-01-25  5:23   ` Bruno Randolf
  2011-01-25 12:26   ` Nick Kossifidis
  2011-01-25  5:12 ` [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop Bruno Randolf
                   ` (2 subsequent siblings)
  3 siblings, 2 replies; 14+ messages in thread
From: Bob Copeland @ 2011-01-25  4:31 UTC (permalink / raw)
  To: linville
  Cc: linux-wireless, mickflemm, Bruno Randolf, jirislaby, lrodriguez,
	Bob Copeland

The ath5k version of ieee80211_generic_frame_duration() returns
an __le16 for standard modes but a cpu-endian int for turbo/half/
quarter rates.  Make it always return cpu-endian values.

Signed-off-by: Bob Copeland <me@bobcopeland.com>
---
 drivers/net/wireless/ath/ath5k/pcu.c |    4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)

diff --git a/drivers/net/wireless/ath/ath5k/pcu.c b/drivers/net/wireless/ath/ath5k/pcu.c
index e5f2b96..a702817 100644
--- a/drivers/net/wireless/ath/ath5k/pcu.c
+++ b/drivers/net/wireless/ath/ath5k/pcu.c
@@ -86,7 +86,7 @@ int ath5k_hw_get_frame_duration(struct ath5k_hw *ah,
 	if (!ah->ah_bwmode) {
 		dur = ieee80211_generic_frame_duration(sc->hw,
 						NULL, len, rate);
-		return dur;
+		return le16_to_cpu(dur);
 	}
 
 	bitrate = rate->bitrate;
@@ -265,8 +265,6 @@ static inline void ath5k_hw_write_rate_duration(struct ath5k_hw *ah)
 		 * what rate we should choose to TX ACKs. */
 		tx_time = ath5k_hw_get_frame_duration(ah, 10, rate);
 
-		tx_time = le16_to_cpu(tx_time);
-
 		ath5k_hw_reg_write(ah, tx_time, reg);
 
 		if (!(rate->flags & IEEE80211_RATE_SHORT_PREAMBLE))
-- 
1.7.1.1



^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop
  2011-01-25  4:31 [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop Bob Copeland
  2011-01-25  4:31 ` [PATCH 2/2] ath5k: correct endianness of frame duration Bob Copeland
@ 2011-01-25  5:12 ` Bruno Randolf
  2011-01-25 12:24 ` Nick Kossifidis
  2011-01-25 13:52 ` Stanislaw Gruszka
  3 siblings, 0 replies; 14+ messages in thread
From: Bruno Randolf @ 2011-01-25  5:12 UTC (permalink / raw)
  To: Bob Copeland; +Cc: linville, linux-wireless, mickflemm, jirislaby, lrodriguez

On Tue January 25 2011 13:31:43 Bob Copeland wrote:
> Review spotted a problem with the error handling in ath5k_hw_dma_stop:
> a successful return from ath5k_hw_stop_tx_dma will be treated as
> an error, so we always bail out of the loop after processing a single
> active queue.  As a result, we may not actually stop some queues during
> reset.
> 
> Signed-off-by: Bob Copeland <me@bobcopeland.com>
> ---
> These two patches fix some buglets I found when reviewing some old code.
> 
>  drivers/net/wireless/ath/ath5k/dma.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/net/wireless/ath/ath5k/dma.c
> b/drivers/net/wireless/ath/ath5k/dma.c index 0064be7..e828b98 100644
> --- a/drivers/net/wireless/ath/ath5k/dma.c
> +++ b/drivers/net/wireless/ath/ath5k/dma.c
> @@ -838,7 +838,7 @@ int ath5k_hw_dma_stop(struct ath5k_hw *ah)
>  	for (i = 0; i < qmax; i++) {
>  		err = ath5k_hw_stop_tx_dma(ah, i);
>  		/* -EINVAL -> queue inactive */
> -		if (err != -EINVAL)
> +		if (err && err != -EINVAL)
>  			return err;
>  	}

Acked-by: Bruno Randolf <br1@einfach.org>

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 2/2] ath5k: correct endianness of frame duration
  2011-01-25  4:31 ` [PATCH 2/2] ath5k: correct endianness of frame duration Bob Copeland
@ 2011-01-25  5:23   ` Bruno Randolf
  2011-01-25 10:38     ` Bob Copeland
  2011-01-25 12:26   ` Nick Kossifidis
  1 sibling, 1 reply; 14+ messages in thread
From: Bruno Randolf @ 2011-01-25  5:23 UTC (permalink / raw)
  To: Bob Copeland; +Cc: linville, linux-wireless, mickflemm, jirislaby, lrodriguez

On Tue January 25 2011 13:31:44 Bob Copeland wrote:
> The ath5k version of ieee80211_generic_frame_duration() returns
> an __le16 for standard modes but a cpu-endian int for turbo/half/
> quarter rates.  Make it always return cpu-endian values.
> 
> Signed-off-by: Bob Copeland <me@bobcopeland.com>
> ---
>  drivers/net/wireless/ath/ath5k/pcu.c |    4 +---
>  1 files changed, 1 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/net/wireless/ath/ath5k/pcu.c
> b/drivers/net/wireless/ath/ath5k/pcu.c index e5f2b96..a702817 100644
> --- a/drivers/net/wireless/ath/ath5k/pcu.c
> +++ b/drivers/net/wireless/ath/ath5k/pcu.c
> @@ -86,7 +86,7 @@ int ath5k_hw_get_frame_duration(struct ath5k_hw *ah,
>  	if (!ah->ah_bwmode) {
>  		dur = ieee80211_generic_frame_duration(sc->hw,
>  						NULL, len, rate);
> -		return dur;
> +		return le16_to_cpu(dur);
>  	}
> 
>  	bitrate = rate->bitrate;
> @@ -265,8 +265,6 @@ static inline void ath5k_hw_write_rate_duration(struct
> ath5k_hw *ah) * what rate we should choose to TX ACKs. */
>  		tx_time = ath5k_hw_get_frame_duration(ah, 10, rate);
> 
> -		tx_time = le16_to_cpu(tx_time);
> -
>  		ath5k_hw_reg_write(ah, tx_time, reg);
> 
>  		if (!(rate->flags & IEEE80211_RATE_SHORT_PREAMBLE))

I wonder what effect this has in ath5k_hw_set_ifs_intervals() where 
ack_tx_time was little endian before...

But the change makes sense.

Acked-by: Bruno Randolf <br1@einfach.org>

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 2/2] ath5k: correct endianness of frame duration
  2011-01-25  5:23   ` Bruno Randolf
@ 2011-01-25 10:38     ` Bob Copeland
  2011-01-25 10:47       ` Bruno Randolf
  0 siblings, 1 reply; 14+ messages in thread
From: Bob Copeland @ 2011-01-25 10:38 UTC (permalink / raw)
  To: Bruno Randolf; +Cc: linville, linux-wireless, mickflemm, jirislaby, lrodriguez

On Tue, Jan 25, 2011 at 02:23:31PM +0900, Bruno Randolf wrote:
> > The ath5k version of ieee80211_generic_frame_duration() returns
> > an __le16 for standard modes but a cpu-endian int for turbo/half/
> > quarter rates.  Make it always return cpu-endian values.
> 
> I wonder what effect this has in ath5k_hw_set_ifs_intervals() where 
> ack_tx_time was little endian before...

Good point, I didn't think about that.  My guess is EIFS would have
been much too large on big endian arches before the patch.  But then
EIFS resets after successful rx so maybe our many BE users (heh)
wouldn't have noticed except on very idle channels...

-- 
Bob Copeland %% www.bobcopeland.com


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 2/2] ath5k: correct endianness of frame duration
  2011-01-25 10:38     ` Bob Copeland
@ 2011-01-25 10:47       ` Bruno Randolf
  2011-01-26 16:17         ` Bob Copeland
  0 siblings, 1 reply; 14+ messages in thread
From: Bruno Randolf @ 2011-01-25 10:47 UTC (permalink / raw)
  To: Bob Copeland; +Cc: linville, linux-wireless, mickflemm, jirislaby, lrodriguez

On Tue January 25 2011 19:38:03 Bob Copeland wrote:
> On Tue, Jan 25, 2011 at 02:23:31PM +0900, Bruno Randolf wrote:
> > > The ath5k version of ieee80211_generic_frame_duration() returns
> > > an __le16 for standard modes but a cpu-endian int for turbo/half/
> > > quarter rates.  Make it always return cpu-endian values.
> > 
> > I wonder what effect this has in ath5k_hw_set_ifs_intervals() where
> > ack_tx_time was little endian before...
> 
> Good point, I didn't think about that.  My guess is EIFS would have
> been much too large on big endian arches before the patch.  But then
> EIFS resets after successful rx so maybe our many BE users (heh)
> wouldn't have noticed except on very idle channels...

Allright, just the EIFS is affected - shouldn't be a big deal. Anyhow it's 
correct now and was wrong before.

But you meant on a very busy channel, right?

I'm on a BE board ;) I can try to see what difference it makes tomorrow.

bruno

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop
  2011-01-25  4:31 [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop Bob Copeland
  2011-01-25  4:31 ` [PATCH 2/2] ath5k: correct endianness of frame duration Bob Copeland
  2011-01-25  5:12 ` [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop Bruno Randolf
@ 2011-01-25 12:24 ` Nick Kossifidis
  2011-01-25 13:52 ` Stanislaw Gruszka
  3 siblings, 0 replies; 14+ messages in thread
From: Nick Kossifidis @ 2011-01-25 12:24 UTC (permalink / raw)
  To: Bob Copeland
  Cc: linville, linux-wireless, Bruno Randolf, jirislaby, lrodriguez

2011/1/25 Bob Copeland <me@bobcopeland.com>:
> Review spotted a problem with the error handling in ath5k_hw_dma_stop:
> a successful return from ath5k_hw_stop_tx_dma will be treated as
> an error, so we always bail out of the loop after processing a single
> active queue.  As a result, we may not actually stop some queues during
> reset.
>
> Signed-off-by: Bob Copeland <me@bobcopeland.com>
> ---
> These two patches fix some buglets I found when reviewing some old code.
>
>  drivers/net/wireless/ath/ath5k/dma.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/ath5k/dma.c b/drivers/net/wireless/ath/ath5k/dma.c
> index 0064be7..e828b98 100644
> --- a/drivers/net/wireless/ath/ath5k/dma.c
> +++ b/drivers/net/wireless/ath/ath5k/dma.c
> @@ -838,7 +838,7 @@ int ath5k_hw_dma_stop(struct ath5k_hw *ah)
>        for (i = 0; i < qmax; i++) {
>                err = ath5k_hw_stop_tx_dma(ah, i);
>                /* -EINVAL -> queue inactive */
> -               if (err != -EINVAL)
> +               if (err && err != -EINVAL)
>                        return err;
>        }
>
> --
> 1.7.1.1

Acked-by: Nick Kossifidis <mickflemm@gmail.com>



-- 
GPG ID: 0xD21DB2DB
As you read this post global entropy rises. Have Fun ;-)
Nick

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 2/2] ath5k: correct endianness of frame duration
  2011-01-25  4:31 ` [PATCH 2/2] ath5k: correct endianness of frame duration Bob Copeland
  2011-01-25  5:23   ` Bruno Randolf
@ 2011-01-25 12:26   ` Nick Kossifidis
  1 sibling, 0 replies; 14+ messages in thread
From: Nick Kossifidis @ 2011-01-25 12:26 UTC (permalink / raw)
  To: Bob Copeland
  Cc: linville, linux-wireless, Bruno Randolf, jirislaby, lrodriguez

2011/1/25 Bob Copeland <me@bobcopeland.com>:
> The ath5k version of ieee80211_generic_frame_duration() returns
> an __le16 for standard modes but a cpu-endian int for turbo/half/
> quarter rates.  Make it always return cpu-endian values.
>
> Signed-off-by: Bob Copeland <me@bobcopeland.com>
> ---
>  drivers/net/wireless/ath/ath5k/pcu.c |    4 +---
>  1 files changed, 1 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/ath5k/pcu.c b/drivers/net/wireless/ath/ath5k/pcu.c
> index e5f2b96..a702817 100644
> --- a/drivers/net/wireless/ath/ath5k/pcu.c
> +++ b/drivers/net/wireless/ath/ath5k/pcu.c
> @@ -86,7 +86,7 @@ int ath5k_hw_get_frame_duration(struct ath5k_hw *ah,
>        if (!ah->ah_bwmode) {
>                dur = ieee80211_generic_frame_duration(sc->hw,
>                                                NULL, len, rate);
> -               return dur;
> +               return le16_to_cpu(dur);
>        }
>
>        bitrate = rate->bitrate;
> @@ -265,8 +265,6 @@ static inline void ath5k_hw_write_rate_duration(struct ath5k_hw *ah)
>                 * what rate we should choose to TX ACKs. */
>                tx_time = ath5k_hw_get_frame_duration(ah, 10, rate);
>
> -               tx_time = le16_to_cpu(tx_time);
> -
>                ath5k_hw_reg_write(ah, tx_time, reg);
>
>                if (!(rate->flags & IEEE80211_RATE_SHORT_PREAMBLE))
> --
> 1.7.1.1

Acked-by: Nick Kossifidis <mickflemm@gmail.com>


-- 
GPG ID: 0xD21DB2DB
As you read this post global entropy rises. Have Fun ;-)
Nick

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop
  2011-01-25  4:31 [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop Bob Copeland
                   ` (2 preceding siblings ...)
  2011-01-25 12:24 ` Nick Kossifidis
@ 2011-01-25 13:52 ` Stanislaw Gruszka
  2011-01-26  1:50   ` Bob Copeland
  3 siblings, 1 reply; 14+ messages in thread
From: Stanislaw Gruszka @ 2011-01-25 13:52 UTC (permalink / raw)
  To: Bob Copeland
  Cc: linville, linux-wireless, mickflemm, Bruno Randolf, jirislaby,
	lrodriguez

On Mon, Jan 24, 2011 at 11:31:43PM -0500, Bob Copeland wrote:
> Review spotted a problem with the error handling in ath5k_hw_dma_stop:
> a successful return from ath5k_hw_stop_tx_dma will be treated as
> an error, so we always bail out of the loop after processing a single
> active queue.  As a result, we may not actually stop some queues during
> reset.
> 
> Signed-off-by: Bob Copeland <me@bobcopeland.com>
> ---
> These two patches fix some buglets I found when reviewing some old code.
> 
>  drivers/net/wireless/ath/ath5k/dma.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/net/wireless/ath/ath5k/dma.c b/drivers/net/wireless/ath/ath5k/dma.c
> index 0064be7..e828b98 100644
> --- a/drivers/net/wireless/ath/ath5k/dma.c
> +++ b/drivers/net/wireless/ath/ath5k/dma.c
> @@ -838,7 +838,7 @@ int ath5k_hw_dma_stop(struct ath5k_hw *ah)
>  	for (i = 0; i < qmax; i++) {
>  		err = ath5k_hw_stop_tx_dma(ah, i);
>  		/* -EINVAL -> queue inactive */
> -		if (err != -EINVAL)
> +		if (err && err != -EINVAL)
>  			return err;
>  	}

Patch is good, but does not make code fully correct. When last queue
is inactive, we return -EINVAL from ath5_hw_dma_stop(). So we need
also:

 		if (err && err != -EINVAL)
 			return err;
+		err = 0;
 	}

But perhaps, would be better just return 0 from 
ath5k_hw_stop_tx_dma() when queue is inactive.

I think that could fix "ath5k phy0: can't reset hardware (-5)"
bugs reported in a few places, so patch should go to stable
as well.

Stanislaw

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop
  2011-01-25 13:52 ` Stanislaw Gruszka
@ 2011-01-26  1:50   ` Bob Copeland
  2011-01-26  7:05     ` Stanislaw Gruszka
  2011-01-26 17:06     ` Nick Kossifidis
  0 siblings, 2 replies; 14+ messages in thread
From: Bob Copeland @ 2011-01-26  1:50 UTC (permalink / raw)
  To: Stanislaw Gruszka
  Cc: linville, linux-wireless, mickflemm, Bruno Randolf, jirislaby,
	lrodriguez

From: Bob Copeland <me@bobcopeland.com>
Date: Mon, 24 Jan 2011 09:25:11 -0500
Subject: [PATCH] ath5k: fix error handling in ath5k_hw_dma_stop

Review spotted a problem with the error handling in ath5k_hw_dma_stop:
a successful return from ath5k_hw_stop_tx_dma will be treated as
an error, so we always bail out of the loop after processing a single
active queue.  As a result, we may not actually stop some queues during
reset.

Signed-off-by: Bob Copeland <me@bobcopeland.com>
---

> Patch is good, but does not make code fully correct. When last queue
> is inactive, we return -EINVAL from ath5_hw_dma_stop(). So we need
> also:
> 
>  		if (err && err != -EINVAL)
>  			return err;
> +		err = 0;
>  	}

> But perhaps, would be better just return 0 from 
> ath5k_hw_stop_tx_dma() when queue is inactive.

How about this version instead?  Although returning 0 in the inactive
queue case would be ok, I'd like to keep the diff small since this
seems to fix some reset problems people are now seeing in Linus's tree
and if so I'd like to get it in 2.6.38.

> I think that could fix "ath5k phy0: can't reset hardware (-5)"
> bugs reported in a few places, so patch should go to stable
> as well.

I thought this was older code but it actually landed after 2.6.37
so no need for stable CC.

As a side note, we still quit when the first error is encountered.
Maybe we should try stopping all of the queues anyway if one fails?
On the other hand we could spend a lot of time polling the registers
if the card is truly hosed, so I think this is best for now.

 drivers/net/wireless/ath/ath5k/dma.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/ath/ath5k/dma.c b/drivers/net/wireless/ath/ath5k/dma.c
index 0064be7..21091c2 100644
--- a/drivers/net/wireless/ath/ath5k/dma.c
+++ b/drivers/net/wireless/ath/ath5k/dma.c
@@ -838,9 +838,9 @@ int ath5k_hw_dma_stop(struct ath5k_hw *ah)
 	for (i = 0; i < qmax; i++) {
 		err = ath5k_hw_stop_tx_dma(ah, i);
 		/* -EINVAL -> queue inactive */
-		if (err != -EINVAL)
+		if (err && err != -EINVAL)
 			return err;
 	}
 
-	return err;
+	return 0;
 }
-- 
1.7.1.1


-- 
Bob Copeland %% www.bobcopeland.com


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop
  2011-01-26  1:50   ` Bob Copeland
@ 2011-01-26  7:05     ` Stanislaw Gruszka
  2011-01-26 17:06     ` Nick Kossifidis
  1 sibling, 0 replies; 14+ messages in thread
From: Stanislaw Gruszka @ 2011-01-26  7:05 UTC (permalink / raw)
  To: Bob Copeland
  Cc: linville, linux-wireless, mickflemm, Bruno Randolf, jirislaby,
	lrodriguez

On Tue, Jan 25, 2011 at 08:50:34PM -0500, Bob Copeland wrote:
> From: Bob Copeland <me@bobcopeland.com>
> Date: Mon, 24 Jan 2011 09:25:11 -0500
> Subject: [PATCH] ath5k: fix error handling in ath5k_hw_dma_stop
> 
> Review spotted a problem with the error handling in ath5k_hw_dma_stop:
> a successful return from ath5k_hw_stop_tx_dma will be treated as
> an error, so we always bail out of the loop after processing a single
> active queue.  As a result, we may not actually stop some queues during
> reset.
> 
> Signed-off-by: Bob Copeland <me@bobcopeland.com>
> ---
> 
> > Patch is good, but does not make code fully correct. When last queue
> > is inactive, we return -EINVAL from ath5_hw_dma_stop(). So we need
> > also:
> > 
> >  		if (err && err != -EINVAL)
> >  			return err;
> > +		err = 0;
> >  	}
> 
> > But perhaps, would be better just return 0 from 
> > ath5k_hw_stop_tx_dma() when queue is inactive.
> 
> How about this version instead? 
It's better :)

> diff --git a/drivers/net/wireless/ath/ath5k/dma.c b/drivers/net/wireless/ath/ath5k/dma.c
> index 0064be7..21091c2 100644
> --- a/drivers/net/wireless/ath/ath5k/dma.c
> +++ b/drivers/net/wireless/ath/ath5k/dma.c
> @@ -838,9 +838,9 @@ int ath5k_hw_dma_stop(struct ath5k_hw *ah)
>  	for (i = 0; i < qmax; i++) {
>  		err = ath5k_hw_stop_tx_dma(ah, i);
>  		/* -EINVAL -> queue inactive */
> -		if (err != -EINVAL)
> +		if (err && err != -EINVAL)
>  			return err;
>  	}
>  
> -	return err;
> +	return 0;
>  }

Reviewed-by: Stanislaw Gruszka <sgruszka@redhat.com>

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 2/2] ath5k: correct endianness of frame duration
  2011-01-25 10:47       ` Bruno Randolf
@ 2011-01-26 16:17         ` Bob Copeland
  0 siblings, 0 replies; 14+ messages in thread
From: Bob Copeland @ 2011-01-26 16:17 UTC (permalink / raw)
  To: Bruno Randolf; +Cc: linville, linux-wireless, mickflemm, jirislaby, lrodriguez

On Tue, Jan 25, 2011 at 5:47 AM, Bruno Randolf <br1@einfach.org> wrote:
> Allright, just the EIFS is affected - shouldn't be a big deal. Anyhow it's
> correct now and was wrong before.
>
> But you meant on a very busy channel, right?
>
> I'm on a BE board ;) I can try to see what difference it makes tomorrow.

Err, yeah, braino.  Glad to know BE actually works :)

-- 
Bob Copeland %% www.bobcopeland.com

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop
  2011-01-26  1:50   ` Bob Copeland
  2011-01-26  7:05     ` Stanislaw Gruszka
@ 2011-01-26 17:06     ` Nick Kossifidis
  2011-01-26 19:28       ` Bob Copeland
  1 sibling, 1 reply; 14+ messages in thread
From: Nick Kossifidis @ 2011-01-26 17:06 UTC (permalink / raw)
  To: Bob Copeland
  Cc: Stanislaw Gruszka, linville, linux-wireless, Bruno Randolf,
	jirislaby, lrodriguez

2011/1/26 Bob Copeland <me@bobcopeland.com>:
>
> As a side note, we still quit when the first error is encountered.
> Maybe we should try stopping all of the queues anyway if one fails?
> On the other hand we could spend a lot of time polling the registers
> if the card is truly hosed, so I think this is best for now.
>

It's better to continue with hw reset if a queue fails to stop, it
usually means the dma unit needs reset.



-- 
GPG ID: 0xD21DB2DB
As you read this post global entropy rises. Have Fun ;-)
Nick

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop
  2011-01-26 17:06     ` Nick Kossifidis
@ 2011-01-26 19:28       ` Bob Copeland
  0 siblings, 0 replies; 14+ messages in thread
From: Bob Copeland @ 2011-01-26 19:28 UTC (permalink / raw)
  To: Nick Kossifidis
  Cc: Stanislaw Gruszka, linville, linux-wireless, Bruno Randolf,
	jirislaby, lrodriguez

On Wed, Jan 26, 2011 at 12:06 PM, Nick Kossifidis <mickflemm@gmail.com> wrote:
> 2011/1/26 Bob Copeland <me@bobcopeland.com>:
>>
>> As a side note, we still quit when the first error is encountered.
>> Maybe we should try stopping all of the queues anyway if one fails?
>> On the other hand we could spend a lot of time polling the registers
>> if the card is truly hosed, so I think this is best for now.
>
> It's better to continue with hw reset if a queue fails to stop, it
> usually means the dma unit needs reset.

Yeah, I thought that may be the case.  So the code as it stands plus
this patch from the thread will do what we want -- continue reset as
soon as any queue exhibits problems.

-- 
Bob Copeland %% www.bobcopeland.com

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2011-01-26 19:28 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-01-25  4:31 [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop Bob Copeland
2011-01-25  4:31 ` [PATCH 2/2] ath5k: correct endianness of frame duration Bob Copeland
2011-01-25  5:23   ` Bruno Randolf
2011-01-25 10:38     ` Bob Copeland
2011-01-25 10:47       ` Bruno Randolf
2011-01-26 16:17         ` Bob Copeland
2011-01-25 12:26   ` Nick Kossifidis
2011-01-25  5:12 ` [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop Bruno Randolf
2011-01-25 12:24 ` Nick Kossifidis
2011-01-25 13:52 ` Stanislaw Gruszka
2011-01-26  1:50   ` Bob Copeland
2011-01-26  7:05     ` Stanislaw Gruszka
2011-01-26 17:06     ` Nick Kossifidis
2011-01-26 19:28       ` Bob Copeland

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.