]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
Add CONFIG_NO_ROAMING option
authorDmitry Shmidt <dimitrysh@google.com>
Tue, 16 Aug 2011 18:55:46 +0000 (11:55 -0700)
committerJouni Malinen <j@w1.fi>
Sat, 25 Feb 2012 16:22:31 +0000 (18:22 +0200)
This can be used to disable wpa_supplicant controlled roaming. It should
be noted that the WPA_DRIVER_FLAGS_BSS_SELECTION capability is the
preferred way for this and CONFIG_NO_ROAMING should be obsoleted once
drivers support the new NL80211_ATTR_ROAM_SUPPORT capability
advertisement.

Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
wpa_supplicant/Android.mk
wpa_supplicant/events.c

index 70d053851970154f518ccdbb0c376dee2f8ce789..5d5f95af37d887e5c56ca1d3c1370960f185f4b1 100644 (file)
@@ -34,6 +34,11 @@ L_CFLAGS = -DWPA_IGNORE_CONFIG_ERRORS
 # Set Android log name
 L_CFLAGS += -DANDROID_LOG_NAME=\"wpa_supplicant\"
 
+# Disable roaming in wpa_supplicant
+ifdef CONFIG_NO_ROAMING
+L_CFLAGS += -DCONFIG_NO_ROAMING
+endif
+
 # Use Android specific directory for control interface sockets
 L_CFLAGS += -DCONFIG_CTRL_IFACE_CLIENT_DIR=\"/data/misc/wifi/sockets\"
 L_CFLAGS += -DCONFIG_CTRL_IFACE_DIR=\"/data/system/wpa_supplicant\"
index 0cc1fc26858d4c319d8bc2e88994af09340941c5..ec027020cdef4530f208c2413f5ceda69c6ab715 100644 (file)
@@ -951,6 +951,7 @@ static int wpa_supplicant_need_to_roam(struct wpa_supplicant *wpa_s,
        if (!current_bss)
                return 1; /* current BSS not seen in scan results */
 
+#ifndef CONFIG_NO_ROAMING
        wpa_dbg(wpa_s, MSG_DEBUG, "Considering within-ESS reassociation");
        wpa_dbg(wpa_s, MSG_DEBUG, "Current BSS: " MACSTR " level=%d",
                MAC2STR(current_bss->bssid), current_bss->level);
@@ -985,6 +986,9 @@ static int wpa_supplicant_need_to_roam(struct wpa_supplicant *wpa_s,
        }
 
        return 1;
+#else /* CONFIG_NO_ROAMING */
+       return 0;
+#endif /* CONFIG_NO_ROAMING */
 }