Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 13594
b: refs/heads/master
c: e758256
h: refs/heads/master
v: v3
  • Loading branch information
Ben Cahill authored and James Ketrenos committed Nov 7, 2005
1 parent 61af231 commit fb032d2
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 8 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: 8935f39e86e3707770e091fb58d9060307edf959
refs/heads/master: e758256104c3c2475f7746bc1b348c99cdb207f2
27 changes: 20 additions & 7 deletions trunk/drivers/net/wireless/ipw2200.c
Original file line number Diff line number Diff line change
Expand Up @@ -4082,6 +4082,11 @@ static void ipw_bg_gather_stats(void *data)
up(&priv->sem);
}

/* Missed beacon behavior:
* 1st missed -> roaming_threshold, just wait, don't do any scan/roam.
* roaming_threshold -> disassociate_threshold, scan and roam for better signal.
* Above disassociate threshold, give up and stop scanning.
* Roaming is disabled if disassociate_threshold <= roaming_threshold */
static inline void ipw_handle_missed_beacon(struct ipw_priv *priv,
int missed_count)
{
Expand Down Expand Up @@ -4116,9 +4121,12 @@ static inline void ipw_handle_missed_beacon(struct ipw_priv *priv,
return;
}

if (missed_count > priv->roaming_threshold) {
if (missed_count > priv->roaming_threshold &&
missed_count <= priv->disassociate_threshold) {
/* If we are not already roaming, set the ROAM
* bit in the status and kick off a scan */
* bit in the status and kick off a scan.
* This can happen several times before we reach
* disassociate_threshold. */
IPW_DEBUG(IPW_DL_NOTIF | IPW_DL_STATE,
"Missed beacon: %d - initiate "
"roaming\n", missed_count);
Expand Down Expand Up @@ -4480,11 +4488,16 @@ static inline void ipw_rx_notification(struct ipw_priv *priv,
STATUS_DISASSOCIATING)))
queue_work(priv->workqueue, &priv->associate);
else if (priv->status & STATUS_ROAMING) {
/* If a scan completed and we are in roam mode, then
* the scan that completed was the one requested as a
* result of entering roam... so, schedule the
* roam work */
queue_work(priv->workqueue, &priv->roam);
if (x->status == SCAN_COMPLETED_STATUS_COMPLETE)
/* If a scan completed and we are in roam mode, then
* the scan that completed was the one requested as a
* result of entering roam... so, schedule the
* roam work */
queue_work(priv->workqueue,
&priv->roam);
else
/* Don't schedule if we aborted the scan */
priv->status &= ~STATUS_ROAMING;
} else if (priv->status & STATUS_SCAN_PENDING)
queue_work(priv->workqueue,
&priv->request_scan);
Expand Down
3 changes: 3 additions & 0 deletions trunk/drivers/net/wireless/ipw2200.h
Original file line number Diff line number Diff line change
Expand Up @@ -590,6 +590,9 @@ struct notif_channel_result {
u8 uReserved;
} __attribute__ ((packed));

#define SCAN_COMPLETED_STATUS_COMPLETE 1
#define SCAN_COMPLETED_STATUS_ABORTED 2

struct notif_scan_complete {
u8 scan_type;
u8 num_channels;
Expand Down

0 comments on commit fb032d2

Please sign in to comment.