[pkg-wpa-devel] r1175 - in /wpasupplicant/trunk/debian: changelog patches/50_wext_dont_overwrite_bss_freq.patch patches/51_dont_reschedule_specific_scans_for_hidden_ssids.patch patches/series
kelmo-guest at users.alioth.debian.org
kelmo-guest at users.alioth.debian.org
Tue Jun 3 12:08:57 UTC 2008
Author: kelmo-guest
Date: Tue Jun 3 12:08:56 2008
New Revision: 1175
URL: http://svn.debian.org/wsvn/pkg-wpa/?sc=1&rev=1175
Log:
* Add 50_wext_dont_overwrite_bss_freq.patch to fix handling of channel and
frequency information returned by mac80211 using drivers in ad-hoc mode.
* 51_dont_reschedule_specific_scans_for_hidden_ssids.patch to optimize scan
rescheduling in order to better detect hidden SSIDs.
Added:
wpasupplicant/trunk/debian/patches/50_wext_dont_overwrite_bss_freq.patch
wpasupplicant/trunk/debian/patches/51_dont_reschedule_specific_scans_for_hidden_ssids.patch
Modified:
wpasupplicant/trunk/debian/changelog
wpasupplicant/trunk/debian/patches/series
Modified: wpasupplicant/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-wpa/wpasupplicant/trunk/debian/changelog?rev=1175&op=diff
==============================================================================
--- wpasupplicant/trunk/debian/changelog (original)
+++ wpasupplicant/trunk/debian/changelog Tue Jun 3 12:08:56 2008
@@ -33,8 +33,12 @@
to use, wext should almost _always_ be used.
* Refresh debian/patches/14_fix_compile_without_eap.patch with what was
applied upstream.
-
- -- Kel Modderman <kel at otaku42.de> Sun, 01 Jun 2008 20:35:25 +1000
+ * Add 50_wext_dont_overwrite_bss_freq.patch to fix handling of channel and
+ frequency information returned by mac80211 using drivers in ad-hoc mode.
+ * 51_dont_reschedule_specific_scans_for_hidden_ssids.patch to optimize scan
+ rescheduling in order to better detect hidden SSIDs.
+
+ -- Kel Modderman <kel at otaku42.de> Tue, 03 Jun 2008 21:31:33 +1000
wpasupplicant (0.6.3-1) unstable; urgency=low
Added: wpasupplicant/trunk/debian/patches/50_wext_dont_overwrite_bss_freq.patch
URL: http://svn.debian.org/wsvn/pkg-wpa/wpasupplicant/trunk/debian/patches/50_wext_dont_overwrite_bss_freq.patch?rev=1175&op=file
==============================================================================
--- wpasupplicant/trunk/debian/patches/50_wext_dont_overwrite_bss_freq.patch (added)
+++ wpasupplicant/trunk/debian/patches/50_wext_dont_overwrite_bss_freq.patch Tue Jun 3 12:08:56 2008
@@ -1,0 +1,35 @@
+From: Dan Williams <dcbw at redhat.com>
+Date: Mon, 2 Jun 2008 17:47:09 +0000 (+0300)
+Subject: wext: don't overwrite BSS frequency
+X-Git-Url: http://w1.fi/gitweb/gitweb.cgi?p=hostap.git;a=commitdiff_plain;h=2e5a7b49a0a52ce36033e4839aae90e638746b6a
+
+wext: don't overwrite BSS frequency
+
+mac80211 sends _both_ channel and frequency in it's scan results, with
+frequency first and channel second (it's since been fixed to send
+channel first and frequency second to work around this issue). This
+results in wpa_supplicant getting the right value when the frequency
+comes, but overwriting the value with '0' when the channel comes because
+wpa_supplicant can't handle 5GHz channel numbers. So if a valid
+previous SIOCGIWFREQ event came in, don't try to overwrite it.
+---
+
+--- a/src/drivers/driver_wext.c
++++ b/src/drivers/driver_wext.c
+@@ -1320,8 +1320,15 @@
+ /*
+ * Some drivers do not report frequency, but a channel.
+ * Try to map this to frequency by assuming they are using
+- * IEEE 802.11b/g.
++ * IEEE 802.11b/g. But don't overwrite a previously parsed
++ * frequency if the driver sends both frequency and channel,
++ * since the driver may be sending an A-band channel that we
++ * don't handle here.
+ */
++
++ if (res->res.freq)
++ return;
++
+ if (iwe->u.freq.m >= 1 && iwe->u.freq.m <= 13) {
+ res->res.freq = 2407 + 5 * iwe->u.freq.m;
+ return;
Added: wpasupplicant/trunk/debian/patches/51_dont_reschedule_specific_scans_for_hidden_ssids.patch
URL: http://svn.debian.org/wsvn/pkg-wpa/wpasupplicant/trunk/debian/patches/51_dont_reschedule_specific_scans_for_hidden_ssids.patch?rev=1175&op=file
==============================================================================
--- wpasupplicant/trunk/debian/patches/51_dont_reschedule_specific_scans_for_hidden_ssids.patch (added)
+++ wpasupplicant/trunk/debian/patches/51_dont_reschedule_specific_scans_for_hidden_ssids.patch Tue Jun 3 12:08:56 2008
@@ -1,0 +1,155 @@
+From: Dan Williams <dcbw at redhat.com>
+Date: Tue, 3 Jun 2008 08:37:48 +0000 (+0300)
+Subject: Do not continually reschedule specific scans to help finding hidden SSIDs
+X-Git-Url: http://w1.fi/gitweb/gitweb.cgi?p=hostap.git;a=commitdiff_plain;h=7e1488494e0150ee7fdef83355266b5633c5c1b0
+
+Do not continually reschedule specific scans to help finding hidden SSIDs
+
+In situations where the driver does background scanning and sends a
+steady stream of scan results, wpa_supplicant would continually
+reschedule the scan. This resulted in specific SSID scans never
+happening for a hidden AP, and the supplicant never connecting to the AP
+because it never got found. Instead, if there's an already scheduled
+scan, and a request comes in to reschedule it, and there are enabled
+scan_ssid=1 network blocks, let the scan happen anyway so the hidden
+SSID has a chance to be found.
+---
+
+--- a/src/utils/eloop.h
++++ b/src/utils/eloop.h
+@@ -207,6 +207,19 @@
+ void *eloop_data, void *user_data);
+
+ /**
++ * eloop_is_timeout_registered - Check if a timeout is already registered
++ * @handler: Matching callback function
++ * @eloop_data: Matching eloop_data
++ * @user_data: Matching user_data
++ * Returns: 1 if the timeout is registered, 0 if the timeout is not registered
++ *
++ * Determine if a matching <handler,eloop_data,user_data> timeout is registered
++ * with eloop_register_timeout().
++ */
++int eloop_is_timeout_registered(eloop_timeout_handler handler,
++ void *eloop_data, void *user_data);
++
++/**
+ * eloop_register_signal - Register handler for signals
+ * @sig: Signal number (e.g., SIGHUP)
+ * @handler: Callback function to be called when the signal is received
+--- a/src/utils/eloop_none.c
++++ b/src/utils/eloop_none.c
+@@ -197,6 +197,26 @@
+ }
+
+
++int eloop_is_timeout_registered(void (*handler)(void *eloop_ctx,
++ void *timeout_ctx),
++ void *eloop_data, void *user_data)
++{
++ struct eloop_timeout *tmp;
++
++ tmp = eloop.timeout;
++ while (tmp != NULL) {
++ if (tmp->handler == handler &&
++ tmp->eloop_data == eloop_data &&
++ tmp->user_data == user_data)
++ return 1;
++
++ tmp = tmp->next;
++ }
++
++ return 0;
++}
++
++
+ /* TODO: replace with suitable signal handler */
+ #if 0
+ static void eloop_handle_signal(int sig)
+--- a/src/utils/eloop_win.c
++++ b/src/utils/eloop_win.c
+@@ -320,6 +320,25 @@
+ }
+
+
++int eloop_is_timeout_registered(eloop_timeout_handler handler,
++ void *eloop_data, void *user_data)
++{
++ struct eloop_timeout *tmp;
++
++ tmp = eloop.timeout;
++ while (tmp != NULL) {
++ if (tmp->handler == handler &&
++ tmp->eloop_data == eloop_data &&
++ tmp->user_data == user_data)
++ return 1;
++
++ tmp = tmp->next;
++ }
++
++ return 0;
++}
++
++
+ /* TODO: replace with suitable signal handler */
+ #if 0
+ static void eloop_handle_signal(int sig)
+--- a/wpa_supplicant/scan.c
++++ b/wpa_supplicant/scan.c
+@@ -172,6 +172,28 @@
+ */
+ void wpa_supplicant_req_scan(struct wpa_supplicant *wpa_s, int sec, int usec)
+ {
++ /* If there's at least one network that should be specifically scanned
++ * then don't cancel the scan and reschedule. Some drivers do
++ * background scanning which generates frequent scan results, and that
++ * causes the specific SSID scan to get continually pushed back and
++ * never happen, which causes hidden APs to never get probe-scanned.
++ */
++ if (eloop_is_timeout_registered(wpa_supplicant_scan, wpa_s, NULL) &&
++ wpa_s->conf->ap_scan == 1) {
++ struct wpa_ssid *ssid = wpa_s->conf->ssid;
++
++ while (ssid) {
++ if (!ssid->disabled && ssid->scan_ssid)
++ break;
++ ssid = ssid->next;
++ }
++ if (ssid) {
++ wpa_msg(wpa_s, MSG_DEBUG, "Not rescheduling scan to "
++ "ensure that specific SSID scans occur");
++ return;
++ }
++ }
++
+ wpa_msg(wpa_s, MSG_DEBUG, "Setting scan request: %d sec %d usec",
+ sec, usec);
+ eloop_cancel_timeout(wpa_supplicant_scan, wpa_s, NULL);
+--- a/src/utils/eloop.c
++++ b/src/utils/eloop.c
+@@ -312,6 +312,25 @@
+ }
+
+
++int eloop_is_timeout_registered(eloop_timeout_handler handler,
++ void *eloop_data, void *user_data)
++{
++ struct eloop_timeout *tmp;
++
++ tmp = eloop.timeout;
++ while (tmp != NULL) {
++ if (tmp->handler == handler &&
++ tmp->eloop_data == eloop_data &&
++ tmp->user_data == user_data)
++ return 1;
++
++ tmp = tmp->next;
++ }
++
++ return 0;
++}
++
++
+ #ifndef CONFIG_NATIVE_WINDOWS
+ static void eloop_handle_alarm(int sig)
+ {
Modified: wpasupplicant/trunk/debian/patches/series
URL: http://svn.debian.org/wsvn/pkg-wpa/wpasupplicant/trunk/debian/patches/series?rev=1175&op=diff
==============================================================================
--- wpasupplicant/trunk/debian/patches/series (original)
+++ wpasupplicant/trunk/debian/patches/series Tue Jun 3 12:08:56 2008
@@ -12,3 +12,5 @@
41_manpage_format_fixes.patch
42_manpage_explain_available_drivers.patch
43_remove_w_from_help.patch
+50_wext_dont_overwrite_bss_freq.patch
+51_dont_reschedule_specific_scans_for_hidden_ssids.patch
More information about the Pkg-wpa-devel
mailing list