linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mac80211: use beacons for connection monitoring
@ 2009-07-29 21:32 Reinette Chatre
  2009-07-29 21:39 ` Ben Greear
                   ` (2 more replies)
  0 siblings, 3 replies; 23+ messages in thread
From: Reinette Chatre @ 2009-07-29 21:32 UTC (permalink / raw)
  To: johannes; +Cc: linville, linux-wireless, Reinette Chatre

From: Reinette Chatre <reinette.chatre@intel.com>

The connection monitor currently relies on probe requests paired
with probe responses to ensure that a connection is alive. This is
fragile in some environments where probe responses can get lost.
When we receive beacons we can also consider the connection to be
alive, so cancel connection poll instance when we receive a beacon.

The debug message "cancelling probereq poll due to a received beacon"
is removed as part of this change as this case is hit very often after
the above change and debug log receives significant number of these messages.

Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
---
 net/mac80211/mlme.c |   12 ++++--------
 1 files changed, 4 insertions(+), 8 deletions(-)

diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
index e3b3156..9cf6153 100644
--- a/net/mac80211/mlme.c
+++ b/net/mac80211/mlme.c
@@ -1743,14 +1743,10 @@ static void ieee80211_rx_mgmt_beacon(struct ieee80211_sub_if_data *sdata,
 	if (memcmp(bssid, mgmt->bssid, ETH_ALEN) != 0)
 		return;
 
-	if (ifmgd->flags & IEEE80211_STA_BEACON_POLL) {
-#ifdef CONFIG_MAC80211_VERBOSE_DEBUG
-		if (net_ratelimit()) {
-			printk(KERN_DEBUG "%s: cancelling probereq poll due "
-			       "to a received beacon\n", sdata->dev->name);
-		}
-#endif
-		ifmgd->flags &= ~IEEE80211_STA_BEACON_POLL;
+	if (ifmgd->flags & (IEEE80211_STA_BEACON_POLL |
+			    IEEE80211_STA_CONNECTION_POLL)) {
+		ifmgd->flags &= ~(IEEE80211_STA_BEACON_POLL |
+				  IEEE80211_STA_CONNECTION_POLL);
 		mutex_lock(&local->iflist_mtx);
 		ieee80211_recalc_ps(local, -1);
 		mutex_unlock(&local->iflist_mtx);
-- 
1.5.6.3


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

end of thread, other threads:[~2009-07-31 14:06 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-07-29 21:32 [PATCH] mac80211: use beacons for connection monitoring Reinette Chatre
2009-07-29 21:39 ` Ben Greear
2009-07-30 10:30   ` Johannes Berg
2009-07-30 14:41     ` Ben Greear
2009-07-30 17:45     ` reinette chatre
2009-07-30 19:47       ` Johannes Berg
2009-07-29 21:45 ` Johannes Berg
2009-07-29 21:50   ` reinette chatre
2009-07-30  5:24     ` Maxim Levitsky
2009-07-29 22:10   ` Ben Greear
2009-07-30 10:28     ` Johannes Berg
2009-07-30  2:39   ` Marcel Holtmann
2009-07-30  9:36   ` Helmut Schaa
2009-07-30  9:54     ` Johannes Berg
2009-07-31  7:08 ` Maxim Levitsky
2009-07-31  7:43   ` Johannes Berg
2009-07-31  7:58     ` Johannes Berg
2009-07-31  8:04       ` Maxim Levitsky
2009-07-31  9:41         ` Marcel Holtmann
2009-07-31 13:19     ` Maxim Levitsky
2009-07-31 13:39       ` Johannes Berg
2009-07-31 13:56         ` Maxim Levitsky
2009-07-31 14:06           ` Johannes Berg

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).