* B43 no beacon ?
@ 2009-05-11 20:31 Matthieu CASTET
2009-05-12 22:39 ` Matthieu CASTET
2009-05-18 8:53 ` [PATCH] b43/legacy: fix beacon change processing Johannes Berg
0 siblings, 2 replies; 4+ messages in thread
From: Matthieu CASTET @ 2009-05-11 20:31 UTC (permalink / raw)
To: linux-wireless
Hi,
I have trying to use openwrt head on a router with a 4306 (core rev 5).
It use the compat-wireless-2009-05-08 as wireless driver and 4.150.10.5 firmware
I have no problem to associate and transmit data with one wifi card, but with
another I got missed beacon errors.
After putting a wifi card in monitor mode, I saw that the 4306 never send beacon
frame.
Do you have any idea why the 4306 AP never generate beacon frame ?
Thanks
Matthieu
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: B43 no beacon ?
2009-05-11 20:31 B43 no beacon ? Matthieu CASTET
@ 2009-05-12 22:39 ` Matthieu CASTET
2009-05-18 8:53 ` [PATCH] b43/legacy: fix beacon change processing Johannes Berg
1 sibling, 0 replies; 4+ messages in thread
From: Matthieu CASTET @ 2009-05-12 22:39 UTC (permalink / raw)
To: linux-wireless
Hi,
after some tracing, it seems to BSS_CHANGED_BSSID flag is never set and we never
call b43_update_templates.
Removing the changed & BSS_CHANGED_BSSID check (from [1]) make the beacon work
Matthieu
[1]
http://git.kernel.org/?p=linux/kernel/git/linville/wireless-next-2.6.git;a=commitdiff;h=2d0ddec5b2b859f06116f631fc0ffe94fbceb556
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH] b43/legacy: fix beacon change processing
2009-05-11 20:31 B43 no beacon ? Matthieu CASTET
2009-05-12 22:39 ` Matthieu CASTET
@ 2009-05-18 8:53 ` Johannes Berg
2009-05-18 18:19 ` Michael Buesch
1 sibling, 1 reply; 4+ messages in thread
From: Johannes Berg @ 2009-05-18 8:53 UTC (permalink / raw)
To: Matthieu CASTET
Cc: linux-wireless, Larry Finger, Michael Buesch, John W. Linville
Process beacon change even if the BSSID doesn't
change at the same time. Also fix what I think
is a small locking error in b43legacy, there's
a spin_unlock_irqrestore that looks out of place.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
---
drivers/net/wireless/b43/main.c | 24 +++++++++++-------------
drivers/net/wireless/b43legacy/main.c | 21 +++++++++------------
2 files changed, 20 insertions(+), 25 deletions(-)
--- wireless-testing.orig/drivers/net/wireless/b43/main.c 2009-05-18 10:44:35.000000000 +0200
+++ wireless-testing/drivers/net/wireless/b43/main.c 2009-05-18 10:48:00.000000000 +0200
@@ -3553,27 +3553,25 @@ static void b43_op_bss_info_changed(stru
B43_WARN_ON(wl->vif != vif);
+ spin_lock_irqsave(&wl->irq_lock, flags);
if (changed & BSS_CHANGED_BSSID) {
- spin_lock_irqsave(&wl->irq_lock, flags);
if (conf->bssid)
memcpy(wl->bssid, conf->bssid, ETH_ALEN);
else
memset(wl->bssid, 0, ETH_ALEN);
+ }
- if (b43_status(dev) >= B43_STAT_INITIALIZED) {
- if (b43_is_mode(wl, NL80211_IFTYPE_AP) ||
- b43_is_mode(wl, NL80211_IFTYPE_MESH_POINT)) {
- B43_WARN_ON(vif->type != wl->if_type);
- if (changed & BSS_CHANGED_BEACON)
- b43_update_templates(wl);
- } else if (b43_is_mode(wl, NL80211_IFTYPE_ADHOC)) {
- if (changed & BSS_CHANGED_BEACON)
- b43_update_templates(wl);
- }
+ if (b43_status(dev) >= B43_STAT_INITIALIZED) {
+ if (changed & BSS_CHANGED_BEACON &&
+ (b43_is_mode(wl, NL80211_IFTYPE_AP) ||
+ b43_is_mode(wl, NL80211_IFTYPE_MESH_POINT) ||
+ b43_is_mode(wl, NL80211_IFTYPE_ADHOC)))
+ b43_update_templates(wl);
+
+ if (changed & BSS_CHANGED_BSSID)
b43_write_mac_bssid_templates(dev);
- }
- spin_unlock_irqrestore(&wl->irq_lock, flags);
}
+ spin_unlock_irqrestore(&wl->irq_lock, flags);
b43_mac_suspend(dev);
--- wireless-testing.orig/drivers/net/wireless/b43legacy/main.c 2009-05-18 10:48:25.000000000 +0200
+++ wireless-testing/drivers/net/wireless/b43legacy/main.c 2009-05-18 10:50:04.000000000 +0200
@@ -2820,27 +2820,24 @@ static void b43legacy_op_bss_info_change
savedirqs = b43legacy_interrupt_disable(dev, B43legacy_IRQ_ALL);
if (changed & BSS_CHANGED_BSSID) {
- spin_unlock_irqrestore(&wl->irq_lock, flags);
b43legacy_synchronize_irq(dev);
if (conf->bssid)
memcpy(wl->bssid, conf->bssid, ETH_ALEN);
else
memset(wl->bssid, 0, ETH_ALEN);
+ }
+
+ if (b43legacy_status(dev) >= B43legacy_STAT_INITIALIZED) {
+ if (changed & BSS_CHANGED_BEACON &&
+ (b43legacy_is_mode(wl, NL80211_IFTYPE_AP) ||
+ b43legacy_is_mode(wl, NL80211_IFTYPE_ADHOC)))
+ b43legacy_update_templates(wl);
- if (b43legacy_status(dev) >= B43legacy_STAT_INITIALIZED) {
- if (b43legacy_is_mode(wl, NL80211_IFTYPE_AP)) {
- B43legacy_WARN_ON(vif->type != NL80211_IFTYPE_AP);
- if (changed & BSS_CHANGED_BEACON)
- b43legacy_update_templates(wl);
- } else if (b43legacy_is_mode(wl, NL80211_IFTYPE_ADHOC)) {
- if (changed & BSS_CHANGED_BEACON)
- b43legacy_update_templates(wl);
- }
+ if (changed & BSS_CHANGED_BSSID)
b43legacy_write_mac_bssid_templates(dev);
- }
- spin_unlock_irqrestore(&wl->irq_lock, flags);
}
+ spin_unlock_irqrestore(&wl->irq_lock, flags);
b43legacy_mac_suspend(dev);
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] b43/legacy: fix beacon change processing
2009-05-18 8:53 ` [PATCH] b43/legacy: fix beacon change processing Johannes Berg
@ 2009-05-18 18:19 ` Michael Buesch
0 siblings, 0 replies; 4+ messages in thread
From: Michael Buesch @ 2009-05-18 18:19 UTC (permalink / raw)
To: Johannes Berg
Cc: Matthieu CASTET, linux-wireless, Larry Finger, John W. Linville
On Monday 18 May 2009 10:53:18 Johannes Berg wrote:
> Process beacon change even if the BSSID doesn't
> change at the same time. Also fix what I think
ACK.
> is a small locking error in b43legacy, there's
> a spin_unlock_irqrestore that looks out of place.
Yeah, I think a patch was already submitted by larry.
> Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
--
Greetings, Michael.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-05-18 18:21 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-05-11 20:31 B43 no beacon ? Matthieu CASTET
2009-05-12 22:39 ` Matthieu CASTET
2009-05-18 8:53 ` [PATCH] b43/legacy: fix beacon change processing Johannes Berg
2009-05-18 18:19 ` 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).