Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 63724
b: refs/heads/master
c: fdc8f43
h: refs/heads/master
v: v3
  • Loading branch information
Michael Buesch authored and John W. Linville committed Aug 6, 2007
1 parent 9287568 commit 2dfb815
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 69dad6e563140ce8578749a8c8651b7f1db8cdbc
refs/heads/master: fdc8f43b5e49b64b251bb48da95193a13ac0132f
11 changes: 8 additions & 3 deletions trunk/net/ieee80211/softmac/ieee80211softmac_wx.c
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ ieee80211softmac_wx_set_essid(struct net_device *net_dev,
struct ieee80211softmac_auth_queue_item *authptr;
int length = 0;

check_assoc_again:
mutex_lock(&sm->associnfo.mutex);

/* Check if we're already associating to this or another network
* If it's another network, cancel and start over with our new network
* If it's our network, ignore the change, we're already doing it!
Expand All @@ -98,13 +98,18 @@ ieee80211softmac_wx_set_essid(struct net_device *net_dev,
cancel_delayed_work(&authptr->work);
sm->associnfo.bssvalid = 0;
sm->associnfo.bssfixed = 0;
flush_scheduled_work();
sm->associnfo.associating = 0;
sm->associnfo.associated = 0;
/* We must unlock to avoid deadlocks with the assoc workqueue
* on the associnfo.mutex */
mutex_unlock(&sm->associnfo.mutex);
flush_scheduled_work();
/* Avoid race! Check assoc status again. Maybe someone started an
* association while we flushed. */
goto check_assoc_again;
}
}


sm->associnfo.static_essid = 0;
sm->associnfo.assoc_wait = 0;

Expand Down

0 comments on commit 2dfb815

Please sign in to comment.