aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant
diff options
context:
space:
mode:
authorJouni Malinen <jouni@qca.qualcomm.com>2013-11-28 13:34:24 (GMT)
committerJouni Malinen <j@w1.fi>2013-12-26 18:50:28 (GMT)
commit9d2cb3ec94f3a96864b680de5a8cec0aeed0ff94 (patch)
tree27ed7437b97c058d7dec3b47d8bad21bbb9b7c4e /wpa_supplicant
parent662b40b16b2d41bb5997a1875d41cf8a0dabc663 (diff)
downloadhostap-9d2cb3ec94f3a96864b680de5a8cec0aeed0ff94.zip
hostap-9d2cb3ec94f3a96864b680de5a8cec0aeed0ff94.tar.gz
hostap-9d2cb3ec94f3a96864b680de5a8cec0aeed0ff94.tar.bz2
Make CONFIG_TESTING_OPTIONS=y enable all testing options
This makes it easier to enable various testing parameters and functionality in build configuration. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
Diffstat (limited to 'wpa_supplicant')
-rw-r--r--wpa_supplicant/Makefile6
-rw-r--r--wpa_supplicant/ctrl_iface.c4
2 files changed, 8 insertions, 2 deletions
diff --git a/wpa_supplicant/Makefile b/wpa_supplicant/Makefile
index 8ade64c..2c709c3 100644
--- a/wpa_supplicant/Makefile
+++ b/wpa_supplicant/Makefile
@@ -15,6 +15,12 @@ CFLAGS += -I$(abspath ../src/utils)
-include .config
+ifdef CONFIG_TESTING_OPTIONS
+CFLAGS += -DCONFIG_TESTING_OPTIONS
+CONFIG_WPS_TESTING=y
+CONFIG_TDLS_TESTING=y
+endif
+
BINALL=wpa_supplicant wpa_cli
ifndef CONFIG_NO_WPA_PASSPHRASE
diff --git a/wpa_supplicant/ctrl_iface.c b/wpa_supplicant/ctrl_iface.c
index f09c886..0495c5b 100644
--- a/wpa_supplicant/ctrl_iface.c
+++ b/wpa_supplicant/ctrl_iface.c
@@ -361,13 +361,13 @@ static int wpa_supplicant_ctrl_iface_set(struct wpa_supplicant *wpa_s,
} else if (os_strcasecmp(cmd, "ampdu") == 0) {
if (wpa_drv_ampdu(wpa_s, atoi(value)) < 0)
ret = -1;
+#ifdef CONFIG_TDLS
#ifdef CONFIG_TDLS_TESTING
} else if (os_strcasecmp(cmd, "tdls_testing") == 0) {
extern unsigned int tdls_testing;
tdls_testing = strtol(value, NULL, 0);
wpa_printf(MSG_DEBUG, "TDLS: tdls_testing=0x%x", tdls_testing);
#endif /* CONFIG_TDLS_TESTING */
-#ifdef CONFIG_TDLS
} else if (os_strcasecmp(cmd, "tdls_disabled") == 0) {
int disabled = atoi(value);
wpa_printf(MSG_DEBUG, "TDLS: tdls_disabled=%d", disabled);
@@ -5172,11 +5172,11 @@ static void wpa_supplicant_ctrl_iface_flush(struct wpa_supplicant *wpa_s)
wpa_s->after_wps = 0;
wpa_s->known_wps_freq = 0;
+#ifdef CONFIG_TDLS
#ifdef CONFIG_TDLS_TESTING
extern unsigned int tdls_testing;
tdls_testing = 0;
#endif /* CONFIG_TDLS_TESTING */
-#ifdef CONFIG_TDLS
wpa_drv_tdls_oper(wpa_s, TDLS_ENABLE, NULL);
wpa_tdls_enable(wpa_s->wpa, 1);
#endif /* CONFIG_TDLS */