rpms/kernel/F-11 mac80211-don-t-drop-nullfunc-frames-during-software.patch, NONE, 1.1 kernel.spec, 1.1618, 1.1619
Kyle McMartin
kyle at fedoraproject.org
Fri May 22 02:06:20 UTC 2009
Author: kyle
Update of /cvs/pkgs/rpms/kernel/F-11
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv19523
Modified Files:
kernel.spec
Added Files:
mac80211-don-t-drop-nullfunc-frames-during-software.patch
Log Message:
* Thu May 21 2009 Kyle McMartin <kyle at redhat.com> - 2.6.29.3-157
- mac80211-don-t-drop-nullfunc-frames-during-software.patch:
upstream a9a6ffffd05f97e6acbdeafc595e269855829751.
mac80211-don-t-drop-nullfunc-frames-during-software.patch:
--- NEW FILE mac80211-don-t-drop-nullfunc-frames-during-software.patch ---
>From 91afa7a151a0fdce2b7d27d39ecbfc40e1b3e8ad Mon Sep 17 00:00:00 2001
From: Kalle Valo <kalle.valo at nokia.com>
Date: Wed, 18 Mar 2009 14:06:44 +0200
Subject: [PATCH] mac80211: don't drop nullfunc frames during software scan
ieee80211_tx_h_check_assoc() was dropping everything else than probe
requests during software scan. So the nullfunc frame with the power save
bit was dropped and AP never received it. This meant that AP never
buffered any frames for the station during software scan.
Fix this by allowing to transmit both probe request and nullfunc frames
during software scan. Tested with stlc45xx.
Signed-off-by: Kalle Valo <kalle.valo at nokia.com>
Acked-by: Johannes Berg <johannes at sipsolutions.net>
Signed-off-by: John W. Linville <linville at tuxdriver.com>
---
net/mac80211/scan.c | 13 +++++++++++++
net/mac80211/tx.c | 14 +++++++++++++-
2 files changed, 26 insertions(+), 1 deletions(-)
diff --git a/net/mac80211/scan.c b/net/mac80211/scan.c
index f5c7c33..1389f29 100644
--- a/net/mac80211/scan.c
+++ b/net/mac80211/scan.c
@@ -631,6 +631,19 @@ int ieee80211_start_scan(struct ieee80211_sub_if_data *scan_sdata,
return 0;
}
+ /*
+ * Hardware/driver doesn't support hw_scan, so use software
+ * scanning instead. First send a nullfunc frame with power save
+ * bit on so that AP will buffer the frames for us while we are not
+ * listening, then send probe requests to each channel and wait for
+ * the responses. After all channels are scanned, tune back to the
+ * original channel and send a nullfunc frame with power save bit
+ * off to trigger the AP to send us all the buffered frames.
+ *
+ * Note that while local->sw_scanning is true everything else but
+ * nullfunc frames and probe requests will be dropped in
+ * ieee80211_tx_h_check_assoc().
+ */
local->sw_scanning = true;
rcu_read_lock();
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
index 37e3d5e..c45d275 100644
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -192,7 +192,19 @@ ieee80211_tx_h_check_assoc(struct ieee80211_tx_data *tx)
return TX_CONTINUE;
if (unlikely(tx->local->sw_scanning) &&
- !ieee80211_is_probe_req(hdr->frame_control))
+ !ieee80211_is_probe_req(hdr->frame_control) &&
+ !ieee80211_is_nullfunc(hdr->frame_control))
+ /*
+ * When software scanning only nullfunc frames (to notify
+ * the sleep state to the AP) and probe requests (for the
+ * active scan) are allowed, all other frames should not be
+ * sent and we should not get here, but if we do
+ * nonetheless, drop them to avoid sending them
+ * off-channel. See the link below and
+ * ieee80211_start_scan() for more.
+ *
+ * http://article.gmane.org/gmane.linux.kernel.wireless.general/30089
+ */
return TX_DROP;
if (tx->sdata->vif.type == NL80211_IFTYPE_MESH_POINT)
--
1.6.2.2
Index: kernel.spec
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/F-11/kernel.spec,v
retrieving revision 1.1618
retrieving revision 1.1619
diff -u -p -r1.1618 -r1.1619
--- kernel.spec 21 May 2009 02:11:27 -0000 1.1618
+++ kernel.spec 22 May 2009 02:05:50 -0000 1.1619
@@ -672,6 +672,7 @@ Patch682: linux-2.6-ipw2x00-age-scan-res
Patch683: linux-2.6-iwl3945-report-killswitch-changes-even-if-the-interface-is-down.patch
Patch684: linux-2.6-iwlagn-fix-hw-rfkill-while-the-interface-is-down.patch
Patch685: linux-2.6-mac80211-fix-beacon-loss-detection-after-scan.patch
+Patch686: mac80211-don-t-drop-nullfunc-frames-during-software.patch
Patch700: linux-2.6-dma-debug-fixes.patch
@@ -1338,6 +1339,8 @@ ApplyPatch linux-2.6-iwlagn-fix-hw-rfkil
# back-port mac80211: fix beacon loss detection after scan
ApplyPatch linux-2.6-mac80211-fix-beacon-loss-detection-after-scan.patch
+ApplyPatch mac80211-don-t-drop-nullfunc-frames-during-software.patch
+
# Fix up DMA debug code
ApplyPatch linux-2.6-dma-debug-fixes.patch
@@ -1999,6 +2002,10 @@ fi
# and build.
%changelog
+* Thu May 21 2009 Kyle McMartin <kyle at redhat.com> - 2.6.29.3-157
+- mac80211-don-t-drop-nullfunc-frames-during-software.patch:
+ upstream a9a6ffffd05f97e6acbdeafc595e269855829751.
+
* Wed May 20 2009 Chuck Ebbert <cebbert at redhat.com> - 2.6.29.3-156
- Enable Divas (formerly Eicon) ISDN drivers on x86_64. (#480837)
More information about the scm-commits
mailing list