aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant/gas_query.c
diff options
context:
space:
mode:
authorKyeyoon Park <kyeyoonp@qca.qualcomm.com>2013-10-21 10:15:45 (GMT)
committerJouni Malinen <j@w1.fi>2013-10-21 10:15:45 (GMT)
commitc3775143377887575ad24d244874ea770249f8c8 (patch)
treeb6b23807805f51d81621c5906a420d3bf6d4cfe0 /wpa_supplicant/gas_query.c
parent24c694b465ea9535436caf85c0e71d4346e15abd (diff)
downloadhostap-c3775143377887575ad24d244874ea770249f8c8.zip
hostap-c3775143377887575ad24d244874ea770249f8c8.tar.gz
hostap-c3775143377887575ad24d244874ea770249f8c8.tar.bz2
GAS: Delay GAS query Tx while scanning/connecting
Offchannel operations needed for a GAS query can conflict with ongoing scan/connection progress, so delay GAS queries if such an operation is in progress on the current interface or any virtual interface sharing the same radio. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
Diffstat (limited to 'wpa_supplicant/gas_query.c')
-rw-r--r--wpa_supplicant/gas_query.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/wpa_supplicant/gas_query.c b/wpa_supplicant/gas_query.c
index a4e675d..00f730e 100644
--- a/wpa_supplicant/gas_query.c
+++ b/wpa_supplicant/gas_query.c
@@ -478,10 +478,16 @@ static void gas_query_timeout(void *eloop_data, void *user_ctx)
static void gas_service_timeout(void *eloop_data, void *user_ctx)
{
struct gas_query *gas = eloop_data;
+ struct wpa_supplicant *wpa_s = gas->wpa_s;
struct gas_query_pending *query = user_ctx;
-
- if (gas->current) {
- wpa_printf(MSG_DEBUG, "GAS: Delaying GAS query Tx while another operation is in progress");
+ int conn;
+
+ conn = wpas_wpa_is_in_progress(wpa_s, 1);
+ if (conn || wpa_s->scanning || gas->current) {
+ wpa_printf(MSG_DEBUG, "GAS: Delaying GAS query Tx while another operation is in progress:%s%s%s",
+ conn ? " connection" : "",
+ wpa_s->scanning ? " scanning" : "",
+ gas->current ? " gas_query" : "");
eloop_register_timeout(
GAS_SERVICE_RETRY_PERIOD_MS / 1000,
(GAS_SERVICE_RETRY_PERIOD_MS % 1000) * 1000,