From: Reinette Chatre <reinette.chatre@intel.com>
To: linville@tuxdriver.com
Cc: linux-wireless@vger.kernel.org,
ipw3945-devel@lists.sourceforge.net,
Johannes Berg <johannes@sipsolutions.net>,
Reinette Chatre <reinette.chatre@intel.com>
Subject: [PATCH 04/11] iwlwifi: support truly passive scanning
Date: Mon, 20 Apr 2009 14:36:57 -0700 [thread overview]
Message-ID: <1240263424-8495-5-git-send-email-reinette.chatre@intel.com> (raw)
In-Reply-To: <1240263424-8495-4-git-send-email-reinette.chatre@intel.com>
From: Johannes Berg <johannes@sipsolutions.net>
If passive scanning is requested we should not ask the
microcode to do active scanning after detecting traffic
on a channel -- that should only be used when an active
scan is requested but some channels are marked passive.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
---
drivers/net/wireless/iwlwifi/iwl-scan.c | 7 ++++++-
drivers/net/wireless/iwlwifi/iwl3945-base.c | 7 ++++++-
2 files changed, 12 insertions(+), 2 deletions(-)
diff --git a/drivers/net/wireless/iwlwifi/iwl-scan.c b/drivers/net/wireless/iwlwifi/iwl-scan.c
index 9edcf8c..25311e1 100644
--- a/drivers/net/wireless/iwlwifi/iwl-scan.c
+++ b/drivers/net/wireless/iwlwifi/iwl-scan.c
@@ -712,7 +712,12 @@ static void iwl_bg_request_scan(struct work_struct *data)
} else if (priv->scan_bands & BIT(IEEE80211_BAND_5GHZ)) {
band = IEEE80211_BAND_5GHZ;
rate = IWL_RATE_6M_PLCP;
- scan->good_CRC_th = IWL_GOOD_CRC_TH;
+ /*
+ * If active scaning is requested but a certain channel
+ * is marked passive, we can do active scanning if we
+ * detect transmissions.
+ */
+ scan->good_CRC_th = is_active ? IWL_GOOD_CRC_TH : 0;
/* Force use of chains B and C (0x6) for scan Rx for 4965
* Avoid A (0x1) because of its off-channel reception on A-band.
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c
index 94f10f2..5520a79 100644
--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c
@@ -3078,7 +3078,12 @@ static void iwl3945_bg_request_scan(struct work_struct *data)
band = IEEE80211_BAND_2GHZ;
} else if (priv->scan_bands & BIT(IEEE80211_BAND_5GHZ)) {
scan->tx_cmd.rate = IWL_RATE_6M_PLCP;
- scan->good_CRC_th = IWL_GOOD_CRC_TH;
+ /*
+ * If active scaning is requested but a certain channel
+ * is marked passive, we can do active scanning if we
+ * detect transmissions.
+ */
+ scan->good_CRC_th = is_active ? IWL_GOOD_CRC_TH : 0;
band = IEEE80211_BAND_5GHZ;
} else {
IWL_WARN(priv, "Invalid scan band count\n");
--
1.5.6.3
next prev parent reply other threads:[~2009-04-20 21:31 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-20 21:36 [PATCH 0/11] iwlwifi driver updates 04/20/2009 Reinette Chatre
2009-04-20 21:36 ` [PATCH v2.6.30 and w-t 01/11] iwlwifi: fix EEPROM validation mask to include OTP only devices Reinette Chatre
2009-04-20 21:36 ` [PATCH 02/11] iwlwifi: rename PROBE_OPTION_MAX_API1 to PROBE_OPTION_MAX_3945 Reinette Chatre
2009-04-20 21:36 ` [PATCH 03/11] iwlwifi: improve scan support Reinette Chatre
2009-04-20 21:36 ` Reinette Chatre [this message]
2009-04-20 21:36 ` [PATCH 05/11] iwl3945: add debugfs to 3945 Reinette Chatre
2009-04-20 21:36 ` [PATCH 06/11] iwl3945: calculate debugfs isr statistics Reinette Chatre
2009-04-20 21:37 ` [PATCH 07/11] iwlwifi: clean up unused NL80211_IFTYPE_MONITOR for Monitor mode Reinette Chatre
2009-04-20 21:37 ` [PATCH 08/11] iwl3945: use cancel_delayed_work_sync to cancel rfkill_poll Reinette Chatre
2009-04-20 21:37 ` [PATCH 09/11] iwlcore: Fix stay in table function Reinette Chatre
2009-04-20 21:37 ` [PATCH 10/11] iwlwifi: remove radio disable parameter Reinette Chatre
2009-04-20 21:37 ` [PATCH 11/11] iwlwifi: allow config if device not ready Reinette Chatre
2009-04-20 21:53 ` [PATCH 08/11] iwl3945: use cancel_delayed_work_sync to cancel rfkill_poll reinette chatre
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1240263424-8495-5-git-send-email-reinette.chatre@intel.com \
--to=reinette.chatre@intel.com \
--cc=ipw3945-devel@lists.sourceforge.net \
--cc=johannes@sipsolutions.net \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox