* [PATCH] b43: remove rate index warning
@ 2008-11-06 16:20 Johannes Berg
2008-11-06 17:05 ` Michael Buesch
0 siblings, 1 reply; 2+ messages in thread
From: Johannes Berg @ 2008-11-06 16:20 UTC (permalink / raw)
To: John Linville; +Cc: Michael Buesch, linux-wireless
I frequently run into this warning, and added some
debugging to see why, and got this:
b43 bad rx: 00000000: 2f d2 e2 63 cf a7 14 04 28 18 c8 5f 88 4a a2 00
bogus junk | plcp | fctl| dur
b43 bad rx: 00000010: 00 11 24 91 07 4d 00 06 25 ff 8f 78 00 06 25 ff
my MAC address | BSSID | AP MAC
b43 bad rx: 00000020: 8f 76 20 74 00 00 42 07 00 20 00 00 00 00 aa aa
| seq | QoS | CCMP IV | data
...
As you can see, there are 6 bogus bytes (sometimes only five) and then
the frame. I don't know why, and I don't see how to recover, so let's
just drop these frames.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
---
drivers/net/wireless/b43/xmit.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- everything.orig/drivers/net/wireless/b43/xmit.c 2008-11-06 16:52:53.000000000 +0100
+++ everything/drivers/net/wireless/b43/xmit.c 2008-11-06 17:10:06.000000000 +0100
@@ -46,7 +46,6 @@ static int b43_plcp_get_bitrate_idx_cck(
case 0x6E:
return 3;
}
- B43_WARN_ON(1);
return -1;
}
@@ -73,7 +72,6 @@ static u8 b43_plcp_get_bitrate_idx_ofdm(
case 0xC:
return base + 7;
}
- B43_WARN_ON(1);
return -1;
}
@@ -608,6 +606,8 @@ void b43_rx(struct b43_wldev *dev, struc
phytype == B43_PHYTYPE_A);
else
status.rate_idx = b43_plcp_get_bitrate_idx_cck(plcp);
+ if (unlikely(status.rate_idx == -1))
+ goto drop;
status.antenna = !!(phystat0 & B43_RX_PHYST0_ANT);
/*
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] b43: remove rate index warning
2008-11-06 16:20 [PATCH] b43: remove rate index warning Johannes Berg
@ 2008-11-06 17:05 ` Michael Buesch
0 siblings, 0 replies; 2+ messages in thread
From: Michael Buesch @ 2008-11-06 17:05 UTC (permalink / raw)
To: Johannes Berg; +Cc: John Linville, linux-wireless
On Thursday 06 November 2008 17:20:24 Johannes Berg wrote:
> I frequently run into this warning, and added some
> debugging to see why, and got this:
>
> b43 bad rx: 00000000: 2f d2 e2 63 cf a7 14 04 28 18 c8 5f 88 4a a2 00
> bogus junk | plcp | fctl| dur
>
> b43 bad rx: 00000010: 00 11 24 91 07 4d 00 06 25 ff 8f 78 00 06 25 ff
> my MAC address | BSSID | AP MAC
> b43 bad rx: 00000020: 8f 76 20 74 00 00 42 07 00 20 00 00 00 00 aa aa
> | seq | QoS | CCMP IV | data
> ...
>
> As you can see, there are 6 bogus bytes (sometimes only five) and then
> the frame. I don't know why, and I don't see how to recover, so let's
> just drop these frames.
>
I don't know why this happens, but I also see it on the opensource firmware.
It might probably be a DMA programming error of some kind. (or just a silicon bug).
But yeah, let's just drop them for now.
> Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Michael Buesch <mb@bu3sch.de>
> ---
> drivers/net/wireless/b43/xmit.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> --- everything.orig/drivers/net/wireless/b43/xmit.c 2008-11-06 16:52:53.000000000 +0100
> +++ everything/drivers/net/wireless/b43/xmit.c 2008-11-06 17:10:06.000000000 +0100
> @@ -46,7 +46,6 @@ static int b43_plcp_get_bitrate_idx_cck(
> case 0x6E:
> return 3;
> }
> - B43_WARN_ON(1);
> return -1;
> }
>
> @@ -73,7 +72,6 @@ static u8 b43_plcp_get_bitrate_idx_ofdm(
> case 0xC:
> return base + 7;
> }
> - B43_WARN_ON(1);
> return -1;
> }
>
> @@ -608,6 +606,8 @@ void b43_rx(struct b43_wldev *dev, struc
> phytype == B43_PHYTYPE_A);
> else
> status.rate_idx = b43_plcp_get_bitrate_idx_cck(plcp);
> + if (unlikely(status.rate_idx == -1))
> + goto drop;
> status.antenna = !!(phystat0 & B43_RX_PHYST0_ANT);
>
> /*
>
>
>
>
--
Greetings Michael.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-11-06 17:06 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-06 16:20 [PATCH] b43: remove rate index warning Johannes Berg
2008-11-06 17:05 ` Michael Buesch
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).